Skip to content
Create a gist now

Instantly share code, notes, and snippets.

system ~/projects/jruby $ jruby -e "foo = proc {|a, b = 1, *c, &d|}; p foo.parameters"
[[:opt, :a], [:opt, :b], [:rest, :c], [:block, :d]]
system ~/projects/jruby $ jruby -e "def foo(a, b = 1, *c, &d); end; p method(:foo).parameters"
[[:req, :a], [:opt, :b], [:rest, :c], [:block, :d]]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.