summaryrefslogtreecommitdiffstats
path: root/Python
diff options
context:
space:
mode:
authorAntoine Pitrou <solipsis@pitrou.net>2010-09-01 18:54:56 (GMT)
committerAntoine Pitrou <solipsis@pitrou.net>2010-09-01 18:54:56 (GMT)
commitfce7fd6426519a2897330c03da7eb889232bf681 (patch)
treeafe2ba5ce7020f102d7c5b5e568643b2e76199ad /Python
parentb0fa831d1e073624d28aa403496f122e2f35697a (diff)
downloadcpython-fce7fd6426519a2897330c03da7eb889232bf681.zip
cpython-fce7fd6426519a2897330c03da7eb889232bf681.tar.gz
cpython-fce7fd6426519a2897330c03da7eb889232bf681.tar.bz2
Issue #9549: sys.setdefaultencoding() and PyUnicode_SetDefaultEncoding()
are now removed, since their effect was inexistent in 3.x (the default encoding is hardcoded to utf-8 and cannot be changed).
Diffstat (limited to 'Python')
-rw-r--r--Python/sysmodule.c20
1 files changed, 0 insertions, 20 deletions
diff --git a/Python/sysmodule.c b/Python/sysmodule.c
index 013f5f1..90c165a 100644
--- a/Python/sysmodule.c
+++ b/Python/sysmodule.c
@@ -183,24 +183,6 @@ implementation."
);
static PyObject *
-sys_setdefaultencoding(PyObject *self, PyObject *args)
-{
- char *encoding;
- if (!PyArg_ParseTuple(args, "s:setdefaultencoding", &encoding))
- return NULL;
- if (PyUnicode_SetDefaultEncoding(encoding))
- return NULL;
- Py_INCREF(Py_None);
- return Py_None;
-}
-
-PyDoc_STRVAR(setdefaultencoding_doc,
-"setdefaultencoding(encoding)\n\
-\n\
-Set the current default string encoding used by the Unicode implementation."
-);
-
-static PyObject *
sys_getfilesystemencoding(PyObject *self)
{
if (Py_FileSystemDefaultEncoding)
@@ -1030,8 +1012,6 @@ static PyMethodDef sys_methods[] = {
#ifdef USE_MALLOPT
{"mdebug", sys_mdebug, METH_VARARGS},
#endif
- {"setdefaultencoding", sys_setdefaultencoding, METH_VARARGS,
- setdefaultencoding_doc},
{"setfilesystemencoding", sys_setfilesystemencoding, METH_VARARGS,
setfilesystemencoding_doc},
{"setcheckinterval", sys_setcheckinterval, METH_VARARGS,