We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent cbdd65f commit 238d596Copy full SHA for 238d596
lib/truffle/truffle/cext_ruby.rb
@@ -15,8 +15,8 @@ module Truffle::CExt
15
# methods defined with rb_define_method are normal Ruby methods therefore they cannot be defined in the cext.rb file
16
# file because blocks passed as arguments would be skipped by org.truffleruby.cext.CExtNodes.BlockProcNode
17
def rb_define_method(mod, name, function, argc)
18
- if argc < -2
19
- raise "Unsupported rb_define_method argc: #{argc}"
+ if argc < -2 or 15 < argc
+ raise ArgumentError, "arity out of range: #{argc} for -2..15"
20
end
21
22
method_body = Truffle::Graal.copy_captured_locals -> *args, &block do
0 commit comments