summaryrefslogtreecommitdiffstats
path: root/Modules/_localemodule.c
diff options
context:
space:
mode:
authorChristian Heimes <christian@cheimes.de>2007-12-02 14:31:20 (GMT)
committerChristian Heimes <christian@cheimes.de>2007-12-02 14:31:20 (GMT)
commit217cfd1c86c59ed8a55ce6d6b88bbe37309e7ba2 (patch)
tree4737b4a91359c94953623ab9ee297e9a90f319e4 /Modules/_localemodule.c
parent1a3284ed69d545e4ef59869998cb8c29233a45fa (diff)
downloadcpython-217cfd1c86c59ed8a55ce6d6b88bbe37309e7ba2.zip
cpython-217cfd1c86c59ed8a55ce6d6b88bbe37309e7ba2.tar.gz
cpython-217cfd1c86c59ed8a55ce6d6b88bbe37309e7ba2.tar.bz2
Cleanup: Replaced most PyInt_ aliases with PyLong_ and disabled the aliases in intobject.h
Diffstat (limited to 'Modules/_localemodule.c')
-rw-r--r--Modules/_localemodule.c24
1 files changed, 12 insertions, 12 deletions
diff --git a/Modules/_localemodule.c b/Modules/_localemodule.c
index f9c48e1..5677b90 100644
--- a/Modules/_localemodule.c
+++ b/Modules/_localemodule.c
@@ -71,7 +71,7 @@ copy_grouping(char* s)
i = -1;
do {
i++;
- val = PyInt_FromLong(s[i]);
+ val = PyLong_FromLong(s[i]);
if (!val)
break;
if (PyList_SetItem(result, i, val)) {
@@ -149,7 +149,7 @@ PyLocale_localeconv(PyObject* self)
Py_XDECREF(x)
#define RESULT_INT(i)\
- x = PyInt_FromLong(l->i);\
+ x = PyLong_FromLong(l->i);\
if (!x) goto failed;\
PyDict_SetItemString(result, #i, x);\
Py_XDECREF(x)
@@ -202,7 +202,7 @@ PyLocale_strcoll(PyObject* self, PyObject* args)
if (!PyArg_ParseTuple(args, "ss:strcoll", &s1, &s2))
return NULL;
- return PyInt_FromLong(strcoll(s1, s2));
+ return PyLong_FromLong(strcoll(s1, s2));
#else
PyObject *os1, *os2, *result = NULL;
wchar_t *ws1 = NULL, *ws2 = NULL;
@@ -234,7 +234,7 @@ PyLocale_strcoll(PyObject* self, PyObject* args)
goto done;
ws2[len2 - 1] = 0;
/* Collate the strings. */
- result = PyInt_FromLong(wcscoll(ws1, ws2));
+ result = PyLong_FromLong(wcscoll(ws1, ws2));
done:
/* Deallocate everything. */
if (ws1) PyMem_FREE(ws1);
@@ -628,37 +628,37 @@ init_locale(void)
d = PyModule_GetDict(m);
- x = PyInt_FromLong(LC_CTYPE);
+ x = PyLong_FromLong(LC_CTYPE);
PyDict_SetItemString(d, "LC_CTYPE", x);
Py_XDECREF(x);
- x = PyInt_FromLong(LC_TIME);
+ x = PyLong_FromLong(LC_TIME);
PyDict_SetItemString(d, "LC_TIME", x);
Py_XDECREF(x);
- x = PyInt_FromLong(LC_COLLATE);
+ x = PyLong_FromLong(LC_COLLATE);
PyDict_SetItemString(d, "LC_COLLATE", x);
Py_XDECREF(x);
- x = PyInt_FromLong(LC_MONETARY);
+ x = PyLong_FromLong(LC_MONETARY);
PyDict_SetItemString(d, "LC_MONETARY", x);
Py_XDECREF(x);
#ifdef LC_MESSAGES
- x = PyInt_FromLong(LC_MESSAGES);
+ x = PyLong_FromLong(LC_MESSAGES);
PyDict_SetItemString(d, "LC_MESSAGES", x);
Py_XDECREF(x);
#endif /* LC_MESSAGES */
- x = PyInt_FromLong(LC_NUMERIC);
+ x = PyLong_FromLong(LC_NUMERIC);
PyDict_SetItemString(d, "LC_NUMERIC", x);
Py_XDECREF(x);
- x = PyInt_FromLong(LC_ALL);
+ x = PyLong_FromLong(LC_ALL);
PyDict_SetItemString(d, "LC_ALL", x);
Py_XDECREF(x);
- x = PyInt_FromLong(CHAR_MAX);
+ x = PyLong_FromLong(CHAR_MAX);
PyDict_SetItemString(d, "CHAR_MAX", x);
Py_XDECREF(x);