NullPointerException when trying to invoke method whose arity is three and that 
is given a block.
-------------------------------------------------------------------------------------------------

                 Key: JRUBY-2646
                 URL: http://jira.codehaus.org/browse/JRUBY-2646
             Project: JRuby
          Issue Type: Bug
          Components: Interpreter
    Affects Versions: JRuby 1.1.2
            Reporter: Tooru TAKAHASHI


NullPointerException when running next script:

{code}
def m(a, b, c)
  yield
end

m(1,2,3) {}
{code}

{quote}
$ jruby -e 'def m(a,b,c); yield; end; m(1,2,3){}' 
Exception in thread "main" java.lang.NullPointerException
        at ruby.__dash_e__.method__0$RUBY$m(-e:1)
        at ruby.__dash_e__Invokermethod__0$RUBY$mFixed3.call(Unknown Source)
        at 
org.jruby.runtime.CallSite$InlineCachingCallSite.cacheAndCall(CallSite.java:235)
        at 
org.jruby.runtime.CallSite$InlineCachingCallSite.call(CallSite.java:414)
        at ruby.__dash_e__.__file__(-e:1)
        at ruby.__dash_e__.__file__(-e)
        at ruby.__dash_e__.load(-e)
        at org.jruby.Ruby.runScript(Ruby.java:512)
        at org.jruby.Ruby.runNormally(Ruby.java:432)
        at org.jruby.Ruby.runFromMain(Ruby.java:312)
        at org.jruby.Main.run(Main.java:144)
        at org.jruby.Main.run(Main.java:89)
        at org.jruby.Main.main(Main.java:80)
{quote}

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: 
http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email


Reply via email to