summaryrefslogtreecommitdiffstats
path: root/Include
diff options
context:
space:
mode:
authorEric Smith <eric@trueblade.com>2009-04-30 01:00:33 (GMT)
committerEric Smith <eric@trueblade.com>2009-04-30 01:00:33 (GMT)
commit58a42244cfefc96b7adada5344b231ff2f32a86a (patch)
treea2a90372b3bef2cc1c06bb9f07b880f2c3997731 /Include
parent738a41dd85f55f49508be62a135f9e65b5c92255 (diff)
downloadcpython-58a42244cfefc96b7adada5344b231ff2f32a86a.zip
cpython-58a42244cfefc96b7adada5344b231ff2f32a86a.tar.gz
cpython-58a42244cfefc96b7adada5344b231ff2f32a86a.tar.bz2
Issue #1588: Add complex.__format__.
Diffstat (limited to 'Include')
-rw-r--r--Include/complexobject.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/Include/complexobject.h b/Include/complexobject.h
index 84b6d8b..8290a6d 100644
--- a/Include/complexobject.h
+++ b/Include/complexobject.h
@@ -54,6 +54,12 @@ PyAPI_FUNC(double) PyComplex_RealAsDouble(PyObject *op);
PyAPI_FUNC(double) PyComplex_ImagAsDouble(PyObject *op);
PyAPI_FUNC(Py_complex) PyComplex_AsCComplex(PyObject *op);
+/* Format the object based on the format_spec, as defined in PEP 3101
+ (Advanced String Formatting). */
+PyAPI_FUNC(PyObject *) _PyComplex_FormatAdvanced(PyObject *obj,
+ Py_UNICODE *format_spec,
+ Py_ssize_t format_spec_len);
+
#ifdef __cplusplus
}
#endif