merging back the new pyshapelib

Bram de Greve bram.degreve at gmail.com
Mon Jan 7 15:07:23 CET 2008


Bernhard Herzog wrote:
> On Friday 04 January 2008 12:07, Bram de Greve wrote:
>   
>> This is caused by a change in the handling of numerical fields in the
>> shapelib C library.  Integer fields of more than 10 characters (as the
>> third column in that file is), are returned as doubles to avoid an
>> overflow.
>>     
>
> Wouldn't it make more sense to return them as long int instead of double at 
> the python level?
>
>   
So you mean from C double back to python long int?  Perhaps.  There's an
API function that does exactly that: PyLong_FromDouble.  Would it be
better to return all integers as long ints in that case?

Bram

> ------------------------------------------------------------------------
>
> _______________________________________________
> Thuban-devel mailing list
> Thuban-devel at intevation.de
> https://intevation.de/mailman/listinfo/thuban-devel
>   




More information about the Thuban-devel mailing list

This site is hosted by Intevation GmbH (Datenschutzerklärung und Impressum | Privacy Policy and Imprint)