Florent Xicluna florent.xicl...@gmail.com added the comment:
This warning is not specific to the _elementtree module.
See related issue #9566.
--
nosy: +eli.bendersky
resolution: - duplicate
status: open - closed
superseder: - Compilation warnings under x64 Windows
Jon Anglin jang...@fortresgrand.com added the comment:
Martin is correct about this patch.
In cases where we really can't propagate Py_ssize_t to (e.g.
XML_Parse), we need to check for an int overflow, and raise
an exception if it does overflow.
Is this an appropriate approach?
int
Changes by Ned Deily n...@acm.org:
--
stage: needs patch - patch review
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue9783
___
___
Martin v. Löwis mar...@v.loewis.de added the comment:
issue9783.diff provides a patch that will compile clean on 32 and 64
bit Windows systems. I tried to avoid explicit casts where I could,
but it was not always possible. I have ported a lot of my company's
code to 64 bit (all Windows
Jon Anglin jang...@fortresgrand.com added the comment:
issue9783.diff provides a patch that will compile clean on 32 and 64 bit
Windows systems. I tried to avoid explicit casts where I could, but it was not
always possible. I have ported a lot of my company's code to 64 bit (all
Windows
Changes by Jon Anglin jang...@fortresgrand.com:
--
nosy: +janglin
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue9783
___
___
Python-bugs-list
Martin v. Löwis mar...@v.loewis.de added the comment:
Instead of
PyLong_FromLong((Py_uintptr_t) self);
use
PyLong_FromVoidPtr(self);
For the others, I suggest making length and allocated Py_ssize_t; this is
likely a pervasive change. Of course, very few people will currently run into
New submission from Antoine Pitrou pit...@free.fr:
Some of these warnings could be serious (e.g. the one where the 64-bit self
is converted to a 32-bit long):
13..\Modules\_elementtree.c(696) : warning C4244: 'function' : conversion from
'Py_uintptr_t' to 'long', possible loss of data