Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Truffle] Resolution of core files consider wrong files and dirs #3144

Closed
eregon opened this issue Jul 16, 2015 · 1 comment
Closed

[Truffle] Resolution of core files consider wrong files and dirs #3144

eregon opened this issue Jul 16, 2015 · 1 comment
Milestone

Comments

@eregon
Copy link
Member

eregon commented Jul 16, 2015

$ mkdir -p core/hash/bla
$  bin/jruby -X+T -e 'p :hi'    
core:/core/hash:1:in `method_missing': undefined local variable or method `bla' for Object (NameError)
    from core:/core/hash:1:in `<main>'
    from core:/core.rb:136:in `<main>'
Truffle internal error: org.jruby.truffle.runtime.control.TruffleFatalException: couldn't load the core library
org.jruby.truffle.runtime.control.TruffleFatalException: couldn't load the core library
    at org.jruby.truffle.runtime.core.CoreLibrary.initializeAfterMethodsAdded(CoreLibrary.java:589)
...

And it even gets to a NoMethodError with the name of the first directory entry?
core:/core.rb:136 is

require_relative 'core/hash' # Our changes
@eregon eregon added the truffle label Jul 16, 2015
@eregon eregon added this to the truffle-dev milestone Jul 16, 2015
@eregon
Copy link
Member Author

eregon commented Jan 14, 2017

It now fails in a different way:

$ jt ruby --jexceptions -e "require_relative 'core/hash'"
java.lang.StringIndexOutOfBoundsException: String index out of range: -1
	at java.lang.String.substring(String.java:1967)
	at org.jruby.truffle.core.kernel.KernelNodes$RequireRelativeNode.dirname(KernelNodes.java:1330)
	at org.jruby.truffle.core.kernel.KernelNodes$RequireRelativeNode.getFullPath(KernelNodes.java:1322)
	at org.jruby.truffle.core.kernel.KernelNodes$RequireRelativeNode.requireRelative(KernelNodes.java:1298)

@eregon eregon closed this as completed Jan 17, 2017
@enebo enebo added this to the Non-Release milestone Dec 7, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants