Patches item #1474907, was opened at 2006-04-23 08:18 Message generated for change (Comment added) made by loewis You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=305470&aid=1474907&group_id=5470
Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: Build Group: None Status: Open Resolution: None Priority: 5 Submitted By: Brett Cannon (bcannon) Assigned to: Martin v. Löwis (loewis) Summary: detect %zd format for PY_FORMAT_SIZE_T Initial Comment: The patch modifies configure.in to add PY_FORMAT_SIZE_T to configure.in (meaning you need to run autoheader on configure.in) so that if %zd is supported for size_t it sets PY_FORMAT_SIZE_T to "z", otherwise it goes undefined and the preprocessor trickery in Include/pyport.h kicks in. This fix removes compiler warnings on OS X 10.4.6 with gcc 4.0.1 thanks to PY_FORMAT_SIZE_T being set to "". Initially assigned to Martin v. Loewis since he said this would be good to do and the Py_ssize_t stuff is his invention. ---------------------------------------------------------------------- >Comment By: Martin v. Löwis (loewis) Date: 2006-04-26 18:15 Message: Logged In: YES user_id=21627 The patch seems to rely on printf returning <0 for the unrecognized format. That seems unreliable: atleast on Linux, printf just outputs the format as-is for unrecognized formats. Instead, I think it should use sprintf, and then check whether the result is the string "0" (in addition to checking whether the printf call itself failed). ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=305470&aid=1474907&group_id=5470 _______________________________________________ Patches mailing list [email protected] http://mail.python.org/mailman/listinfo/patches
