-
-
Save enebo/46c29240755890ca608a4280a488b906 to your computer and use it in GitHub Desktop.
This file contains 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
def bar(*a) | |
p a | |
end | |
bar(1, a: 1) | |
def foo(a, ...) | |
bar(...) | |
end | |
foo(1, 2, 3, **{}) |
This file contains 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
system ~/work/jruby master 2542% mri31 ../snippets/forward1.rb | |
[1, {:a=>1}] | |
[2, 3] | |
system ~/work/jruby master 2543% mri30 ../snippets/forward1.rb | |
[1, {:a=>1}] | |
[2, 3] | |
system ~/work/jruby master 2544% jruby ../snippets/forward1.rb | |
[1, {:a=>1}] | |
[2, 3, {}] | |
system ~/work/jruby master 2545% jruby --dev ../snippets/forward1.rb | |
[1, {:a=>1}] | |
[2, 3] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment