summaryrefslogtreecommitdiffstats
path: root/Modules/mmapmodule.c
diff options
context:
space:
mode:
authorMartin v. Löwis <martin@v.loewis.de>2011-10-09 08:38:36 (GMT)
committerMartin v. Löwis <martin@v.loewis.de>2011-10-09 08:38:36 (GMT)
commitafe55bba33a20f87a58f940186359237064b428f (patch)
tree66d64a1518d79c3d0e90c0a1d0080cd88e887d99 /Modules/mmapmodule.c
parent67df285a3389c7fdb8c7bd301314ac45e17f8074 (diff)
downloadcpython-afe55bba33a20f87a58f940186359237064b428f.zip
cpython-afe55bba33a20f87a58f940186359237064b428f.tar.gz
cpython-afe55bba33a20f87a58f940186359237064b428f.tar.bz2
Add API for static strings, primarily good for identifiers.
Thanks to Konrad Schöbel and Jasper Schulz for helping with the mass-editing.
Diffstat (limited to 'Modules/mmapmodule.c')
-rw-r--r--Modules/mmapmodule.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/Modules/mmapmodule.c b/Modules/mmapmodule.c
index 5d086a7..f4a80c2 100644
--- a/Modules/mmapmodule.c
+++ b/Modules/mmapmodule.c
@@ -702,7 +702,9 @@ mmap__enter__method(mmap_object *self, PyObject *args)
static PyObject *
mmap__exit__method(PyObject *self, PyObject *args)
{
- return PyObject_CallMethod(self, "close", NULL);
+ _Py_identifier(close);
+
+ return _PyObject_CallMethodId(self, &PyId_close, NULL);
}
static struct PyMethodDef mmap_object_methods[] = {