java.awt.Component.instance_of?() expects 2 args
------------------------------------------------
Key: JRUBY-5132
URL: http://jira.codehaus.org/browse/JRUBY-5132
Project: JRuby
Issue Type: Bug
Components: Core Classes/Modules, Java Integration
Affects Versions: JRuby 1.5.3
Environment: WinXP SP2, Java 1.6.0_20-b02
Reporter: Bill Dortch
Calls to instance_of?(aClass) on java.awt.Component (class, not instances) and
any subclasses (including javax.swing.JComponent and subclasses) results in an
argument error. I've dumped the stack at the point the RaiseException is
created:
{noformat}
>jruby -e "require 'java'; puts java.awt.Container.instance_of?(Class)"
java.lang.Exception: Stack trace
at java.lang.Thread.dumpStack(Thread.java:1206)
at org.jruby.Ruby.newArgumentError(Ruby.java:3008)
at
org.jruby.java.invokers.RubyToJavaInvoker.findCallableArityOne(RubyToJavaInvoker.java:230
)
at
org.jruby.java.invokers.StaticMethodInvoker.call(StaticMethodInvoker.java:53)
at
org.jruby.internal.runtime.methods.AliasMethod.call(AliasMethod.java:62)
at
org.jruby.runtime.callsite.CachingCallSite.cacheAndCall(CachingCallSite.java:309)
at
org.jruby.runtime.callsite.CachingCallSite.call(CachingCallSite.java:148)
at ruby.__dash_e__.__file__(-e:1)
at ruby.__dash_e__.load(-e)
at org.jruby.Ruby.runScript(Ruby.java:686)
at org.jruby.Ruby.runNormally(Ruby.java:569)
at org.jruby.Ruby.runFromMain(Ruby.java:415)
at org.jruby.Main.run(Main.java:286)
at org.jruby.Main.run(Main.java:128)
at org.jruby.Main.main(Main.java:97)
-e:1: wrong # of arguments(1 for 2) (ArgumentError)
{noformat}
Also, it's looking for method isInstanceOf. Definitely a weird one.
Worked in 1.4,1,
--
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