diff options
| author | Jared Breeden <[email protected]> | 2015-06-22 23:20:24 -0700 |
|---|---|---|
| committer | Jared Breeden <[email protected]> | 2015-06-22 23:20:24 -0700 |
| commit | 18337266f838003d631d2c02e6d847ae5375a839 (patch) | |
| tree | ccf038939213da30b99ba8931d87bc0d719dbc8a /test | |
| parent | 9781580c7134fcee7bf5a6d4356bc47593549da8 (diff) | |
| parent | 1001be2e99720f6745159295aa73c649e08adec8 (diff) | |
| download | mruby-18337266f838003d631d2c02e6d847ae5375a839.tar.gz mruby-18337266f838003d631d2c02e6d847ae5375a839.zip | |
Merge branch 'master' of http://github.com/mruby/mruby into alloc_doc
Diffstat (limited to 'test')
| -rw-r--r-- | test/t/proc.rb | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/test/t/proc.rb b/test/t/proc.rb index 22ccceb68..888b7d56a 100644 --- a/test/t/proc.rb +++ b/test/t/proc.rb @@ -36,6 +36,14 @@ assert('Proc#arity', '15.2.17.4.2') do assert_equal(-3, b) assert_equal 1, c assert_equal 1, d + + e = ->(x=0, y){}.arity + f = ->((x, y), z=0){}.arity + g = ->(x=0){}.arity + + assert_equal(-2, e) + assert_equal(-2, f) + assert_equal(-1, g) end assert('Proc#call', '15.2.17.4.3') do |
