[IronPython] Can't call non-python instance method with argument name
Dino Viehland
dinov at exchange.microsoft.com
Thu Jan 19 23:22:12 CET 2006
Thanks for the bug report - we hadn't seen this one before. We'll get this fixed for the next beta release.
-----Original Message-----
From: users-bounces at lists.ironpython.com [mailto:users-bounces at lists.ironpython.com] On Behalf Of Oonuki Makoto
Sent: Monday, January 16, 2006 6:48 PM
To: users at lists.ironpython.com
Subject: [IronPython] Can't call non-python instance method with argument name
Hello,
Sorry if this is a known limitation, I've checked ML archive
and the bug tracker though...
I've got the following error with IP1.0 beta1 / .NET 2.0 (japanese).
It seems that IP uses int 10 as the instance instead of R.
---------------
>ironpythonconsole -X:ExceptionDetail
>>> import System
>>> R = System.Random()
>>> R.Next(maxValue=10)
System.Reflection.TargetException: Object does not match target type.
at System.Reflection.RuntimeMethodInfo.CheckConsistency(Object target)
at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture, Boolean skipVisibilityChecks)
at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)
at IronPython.Runtime.ReflectedMethodBase.Invoke(MethodBinding binding)
at IronPython.Runtime.ReflectedMethodBase.Call(Object[] args, String[] names)
at IronPython.Runtime.Ops.Call(Object func, Object[] args, String[] names)
at input##2(Frame )
at IronPython.Runtime.FrameCodeDelegate.Invoke(Frame frame)
at IronPython.Runtime.FrameCode.Run(Frame frame)
at IronPython.Hosting.PythonEngine.DoOneInteractive(Frame topFrame)
at IronPython.Hosting.PythonEngine.RunInteractive()
StandardError: Object does not match target type.
_______________________________________________
users mailing list
users at lists.ironpython.com
http://lists.ironpython.com/listinfo.cgi/users-ironpython.com
More information about the Ironpython-users
mailing list