Implementation of PEP 3101, Advanced String Formatting.

Known issues:

The string.Formatter class, as discussed in the PEP, is incomplete.

Error handling needs to conform to the PEP.

Need to fix this warning that I introduced in Python/formatter_unicode.c:
Objects/stringlib/unicodedefs.h:26: warning: `STRINGLIB_CMP' defined but not used

Need to make sure sign formatting is correct, more tests needed.

Need to remove '()' sign formatting, left over from an earlier version of the PEP.
This commit is contained in:
Eric Smith 2007-08-25 02:26:07 +00:00
parent e4dc324884
commit 8c66326368
22 changed files with 2669 additions and 18 deletions

View file

@ -1437,6 +1437,11 @@ PyAPI_FUNC(Py_UNICODE*) Py_UNICODE_strchr(
const Py_UNICODE *s, Py_UNICODE c
);
PyObject *
_unicodeformatter_iterator(PyObject *str);
PyObject *
_unicodeformatter_lookup(PyObject *field_name, PyObject *args,
PyObject *kwargs);
#ifdef __cplusplus
}