[PyKDE] Re: __truediv__ support in SIP
phil at riverbankcomputing.co.uk
Wed Jan 10 16:25:21 GMT 2007
On Tuesday 09 January 2007 2:36 pm, Giovanni Bajo wrote:
> SIP does not currently support __truediv__. The attached patch lets the
> user manually define it through %MethodCode in a SIP file.
> I think SIP should also automatically generate __truediv__ for
> operator/, with exactly the same code that it uses for __div__. In fact,
> the difference between __truediv__ and __div__ exists only for builtin
> int/float types, for backward compatibility: any other user-defined type
> should define both slots to the same code.
> Phile, how do I make SIP generate __truediv__ code exactly like it does
> for __div__? Or if you have time to handle this yourself, be my guest,
> I'll just sit, relax and grab the snapshot :)
The simpler patch we discussed (an with similar support for __itruediv__) will
be in tonight's snapshot.
More information about the PyQt