Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Browse the repository at this point in the history
Revert "[Truffle] Top-level methods should be public by default."
* This reverts commit 6be4fe2. * They should be private: $ ruby -e 'def m; end; p self.private_methods(false)'
- Loading branch information
ba273a5
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I guess we should have a spec for this then. Reverting this change does break specs for ERB because it changes the semantics of eval. But I'm now thinking it's because our notion of top-level isn't correct.
ba273a5
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It looks like non-Truffle JRuby gets this wrong, too.
ba273a5
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
https://github.com/rubyspec/rubyspec/commit/91ce9f65493a18acc401dc7ded0e79e0226a03c6 should specify the basics of it. Behavior across files probably belongs to
load
orrequire
.ba273a5
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fixed by da135d7.