This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author scoder
Recipients scoder
Date 2012-08-31.05:01:20
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1346389281.37.0.195421488616.issue15827@psf.upfronthosting.co.za>
In-reply-to
Content
Formatting support for "lld"/"llu" was added (I think) in issue 7228, but the definition of PY_FORMAT_SIZE_T wasn't adapted. We are getting test output failures in Cython on Win64 when formatting error messages using the "Id" format, as defined by pyport.h:

"""
#ifndef PY_FORMAT_SIZE_T
#   if SIZEOF_SIZE_T == SIZEOF_INT && !defined(__APPLE__)
#       define PY_FORMAT_SIZE_T ""
#   elif SIZEOF_SIZE_T == SIZEOF_LONG
#       define PY_FORMAT_SIZE_T "l"
#   elif defined(MS_WINDOWS)
#       define PY_FORMAT_SIZE_T "I"
#   else
#       error "This platform's pyconfig.h needs to define PY_FORMAT_SIZE_T"
#   endif
#endif
"""

The "%Id" format is not being resolved in the error messages and shows up in the output instead.

NumPy uses "lld" when available, starting with Py2.7:

https://github.com/numpy/numpy/blob/master/numpy/core/include/numpy/npy_common.h#L66

Shouldn't PY_FORMAT_SIZE_T become "ll" on Win64 directly?
History
Date User Action Args
2012-08-31 05:01:21scodersetrecipients: + scoder
2012-08-31 05:01:21scodersetmessageid: <1346389281.37.0.195421488616.issue15827@psf.upfronthosting.co.za>
2012-08-31 05:01:20scoderlinkissue15827 messages
2012-08-31 05:01:20scodercreate