diff options
author | Guido van Rossum <guido@python.org> | 2002-08-19 21:43:18 (GMT) |
---|---|---|
committer | Guido van Rossum <guido@python.org> | 2002-08-19 21:43:18 (GMT) |
commit | 45ec02aed14685c353e55841b5acbc0dadee76f8 (patch) | |
tree | 0c146fdf0d488f279f0baf64b0f1fa0484274a73 /Include/modsupport.h | |
parent | d8dbf847b6a819ef73d7bf0c05eafbdb9aee9956 (diff) | |
download | cpython-45ec02aed14685c353e55841b5acbc0dadee76f8.zip cpython-45ec02aed14685c353e55841b5acbc0dadee76f8.tar.gz cpython-45ec02aed14685c353e55841b5acbc0dadee76f8.tar.bz2 |
SF patch 576101, by Oren Tirosh: alternative implementation of
interning. I modified Oren's patch significantly, but the basic idea
and most of the implementation is unchanged. Interned strings created
with PyString_InternInPlace() are now mortal, and you must keep a
reference to the resulting string around; use the new function
PyString_InternImmortal() to create immortal interned strings.
Diffstat (limited to 'Include/modsupport.h')
-rw-r--r-- | Include/modsupport.h | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/Include/modsupport.h b/Include/modsupport.h index 2e577ab..7e69921 100644 --- a/Include/modsupport.h +++ b/Include/modsupport.h @@ -23,8 +23,8 @@ PyAPI_FUNC(int) PyModule_AddObject(PyObject *, char *, PyObject *); PyAPI_FUNC(int) PyModule_AddIntConstant(PyObject *, char *, long); PyAPI_FUNC(int) PyModule_AddStringConstant(PyObject *, char *, char *); -#define PYTHON_API_VERSION 1011 -#define PYTHON_API_STRING "1011" +#define PYTHON_API_VERSION 1012 +#define PYTHON_API_STRING "1012" /* The API version is maintained (independently from the Python version) so we can detect mismatches between the interpreter and dynamically loaded modules. These are diagnosed by an error message but @@ -38,6 +38,9 @@ PyAPI_FUNC(int) PyModule_AddStringConstant(PyObject *, char *, char *); Please add a line or two to the top of this log for each API version change: + 19-Aug-2002 GvR 1012 Changes to string object struct for + interning changes, saving 3 bytes. + 17-Jul-2001 GvR 1011 Descr-branch, just to be on the safe side 25-Jan-2001 FLD 1010 Parameters added to PyCode_New() and |