[IronPython] IP 1.0 Beta 2 float to int conversion
dinov at exchange.microsoft.com
Thu Jan 26 18:54:37 CET 2006
We have made some changes in this space but I just haven't found the change that would have affected this yet...
One thing I'm curious about - is getMaxSpliiterDistance C# code or Python code? The reason I ask if I'm wondering if it's returning a float or a double (we represent Python float's w/ doubles, so if it came from a literal it'll be a double).
From: users-bounces at lists.ironpython.com [mailto:users-bounces at lists.ironpython.com] On Behalf Of J. de Hooge
Sent: Thursday, January 26, 2006 8:10 AM
To: users at lists.ironpython.com
Subject: [IronPython] IP 1.0 Beta 2 float to int conversion
Thanks for the new release and all the work invested!
I've just stepped up from IP 0.9.5 to IP 1.0 Beta 2, and I noticed the following:
In 0.9.5 the following runs fine, where self.widget is a Forms.SplitContainer (type: Int32 property) and the r.h.s. is a float, e.g. 100.0:
self.widget.SplitterDistance = self.state * self.getMaxSplitterDistance ()
In 1.0 Beta it will stall with the following message:
No conversion from 100 to System.Int32
Stricktly taken, the IP 1.0 is correct, but I found the auto-conversion convenient.
Has the conversion behaviour been tightened deliberately?
Jacques de Hooge
info at geatec.com
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Ironpython-users