Another C API Question
zyzhu2000 at gmail.com
Fri Jul 27 23:18:56 CEST 2007
On Jul 27, 11:37 am, Farshid Lashkari <n... at spam.com> wrote:
> beginner wrote:
> > This works with PyFloat only. It does not work with integers.
> Did you try it out? I have used it on ints, bools, and objects that
> implement the __float__ method. It does not work on strings though.
I did and it did not seem to work. I ended up doing the following.
Verbose, isn't it?
If I do d=PyFloat_AsDouble(oDiscount); in the third "if", I get an
error. Maybe I missed something obvious.
More information about the Python-list