Skip to content

Commit

Permalink
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
@@ -163,7 +163,7 @@ public RubyRootNode parse(RubyNode currentNode, RubyContext context, Source sour

// Set default top-level visibility
if (parserContext == ParserContext.TOP_LEVEL) {
truffleNode = new SetFrameVisibilityNode(context, truffleNode.getSourceSection(), truffleNode, Visibility.PUBLIC);
truffleNode = new SetFrameVisibilityNode(context, truffleNode.getSourceSection(), truffleNode, Visibility.PRIVATE);
}

// Load flip-flop states

4 comments on commit ba273a5

@nirvdrum
Copy link
Contributor

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.

@nirvdrum
Copy link
Contributor

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.

@eregon
Copy link
Member Author

@eregon eregon commented on ba273a5 Dec 30, 2014

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

vhhxbnn/rubyspec@91ce9f6 should specify the basics of it. Behavior across files probably belongs to load or require.

@eregon
Copy link
Member Author

@eregon eregon commented on ba273a5 Dec 30, 2014

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed by da135d7.

Please sign in to comment.