We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
headius
Learn more about funding links in repositories.
Report abuse
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
Simple enough example, from test/mri/ruby/test_call.rb's test_safe_call_block_*:
test_safe_call_block_*
[] ~/projects/jruby $ ast -e '"a".sub! "b" do end&.foo 1' AST: RootNode 0 CallNode:foo 0 CallNode:sub! 0 StrNode 0 ArrayNode 0 StrNode 0 IterNode 0 ArgsNode 0 ListNode 0 ListNode 0 ListNode 0 ListNode 0 ArrayNode 0 FixnumNode 0 , null
Note that the curly form does get recognized as a lazy call:
[] ~/projects/jruby $ ast -e '"a".sub!("b"){}&.foo 1' AST: RootNode 0 CallNode[lazy]:foo 0 CallNode:sub! 0 StrNode 0 ArrayNode 0 StrNode 0 IterNode 0 ArgsNode 0 ListNode 0 ListNode 0 ListNode 0 ListNode 0 ArrayNode 0 FixnumNode 0 , null
The text was updated successfully, but these errors were encountered:
Add excludes for lonely operator fails from #3567.
bfc4393
This also works if the call itself contains parens:
jruby -e '"a".sub!("b") do end&.foo 1'
Sorry, something went wrong.
Fixes #3567. Parser does not recognize lonely operator after do...end
baecd42
No branches or pull requests
Simple enough example, from test/mri/ruby/test_call.rb's
test_safe_call_block_*
:Note that the curly form does get recognized as a lazy call:
The text was updated successfully, but these errors were encountered: