Merged
Conversation
Member
Author
There was a problem hiding this comment.
Is there a good way to bind the java field with the instance variable?
Member
There was a problem hiding this comment.
Unfortunately not. Either use an instance var or a field, and generally only use the instance var if there's significant code in the wild that expects it to be there. The field will usually be faster.
Member
|
The PR looks like a good start, and I agree we should merge it. I'll see if I can make that happen, since it's not automatically mergable with recent source tree reorg. |
Member
|
Merged! Make sure you rebase to the new layout and read BUILDING.md for changes to the dev workflow. Looking good so far! |
eregon
added a commit
that referenced
this pull request
Jul 7, 2013
This pull request was closed.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This approach is quite similar to how MRI does it.
A good part of the library is still written in Ruby and it would take a considerable effort to translate everything (plus, it might not be very worthy). I think this should be merged in a first step.
The binding
@path<=>pathJava field is done by setting@pathin #initialize, is there a better way?There are a couple TODOs left, to which some light on it could help me.
Updated version of
lib/ruby/1.9/pathname.rbis HEAD of theruby_1_9_3branch (only the require line changes frompathname.sotopathname_ext(is there a better naming, possible to differentiatepathname.{rb,jar}?Should we add back the doc there? (in MRI, it was moved to
pathname.c)About the license, is it copied and adapted rightly?
Tests (
$ bin/jruby test/externals/ruby1.9/pathname/test_pathname.rb) give:The error is due to
IO.opennot being fully 1.9-compliant.The first failure is
ENOENTnot raised withFile.realdirpath(I will try to fix this).The second failure is
ENOENTbeing raised instead ofELOOP(symlink loop).@headius what do you think?