summaryrefslogtreecommitdiffstats
path: root/Modules/_testcapimodule.c
diff options
context:
space:
mode:
authorMark Dickinson <dickinsm@gmail.com>2009-11-15 16:18:58 (GMT)
committerMark Dickinson <dickinsm@gmail.com>2009-11-15 16:18:58 (GMT)
commit82864d1ab101d971e77b73cac9e994fd09cd796b (patch)
tree65335906c1a5f330660bb1f64d698198d50856d3 /Modules/_testcapimodule.c
parentd5b34d4597a7163edf20f831db620b0a4fe57d5d (diff)
downloadcpython-82864d1ab101d971e77b73cac9e994fd09cd796b.zip
cpython-82864d1ab101d971e77b73cac9e994fd09cd796b.tar.gz
cpython-82864d1ab101d971e77b73cac9e994fd09cd796b.tar.bz2
Issue #7228: Add '%lld' and '%llu' support to PyFormat_FromString,
PyFormat_FromStringV and PyErr_Format.
Diffstat (limited to 'Modules/_testcapimodule.c')
-rw-r--r--Modules/_testcapimodule.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/Modules/_testcapimodule.c b/Modules/_testcapimodule.c
index fb5cf73..f2181eb 100644
--- a/Modules/_testcapimodule.c
+++ b/Modules/_testcapimodule.c
@@ -954,6 +954,12 @@ test_string_from_format(PyObject *self, PyObject *args)
CHECK_1_FORMAT("%lu", unsigned long);
CHECK_1_FORMAT("%zu", size_t);
+ /* "%lld" and "%llu" support added in Python 2.7. */
+#ifdef HAVE_LONG_LONG
+ CHECK_1_FORMAT("%llu", unsigned PY_LONG_LONG);
+ CHECK_1_FORMAT("%lld", PY_LONG_LONG);
+#endif
+
Py_RETURN_NONE;
Fail: