diff options
author | Christian Heimes <christian@cheimes.de> | 2008-05-26 13:28:38 (GMT) |
---|---|---|
committer | Christian Heimes <christian@cheimes.de> | 2008-05-26 13:28:38 (GMT) |
commit | 72b710a59617ebe6dd1c41613d2c7eb81702efd9 (patch) | |
tree | cd134cc11c49ba09f50e44a9f36b69f2b0ffc893 /Objects/object.c | |
parent | 9c4756ea265b5ebd71c9ae59f3673c7cecb6f060 (diff) | |
download | cpython-72b710a59617ebe6dd1c41613d2c7eb81702efd9.zip cpython-72b710a59617ebe6dd1c41613d2c7eb81702efd9.tar.gz cpython-72b710a59617ebe6dd1c41613d2c7eb81702efd9.tar.bz2 |
Renamed PyString to PyBytes
Diffstat (limited to 'Objects/object.c')
-rw-r--r-- | Objects/object.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/Objects/object.c b/Objects/object.c index 5dc3436..46cfdfe 100644 --- a/Objects/object.c +++ b/Objects/object.c @@ -291,9 +291,9 @@ internal_print(PyObject *op, FILE *fp, int flags, int nesting) s = PyObject_Repr(op); if (s == NULL) ret = -1; - else if (PyString_Check(s)) { - fwrite(PyString_AS_STRING(s), 1, - PyString_GET_SIZE(s), fp); + else if (PyBytes_Check(s)) { + fwrite(PyBytes_AS_STRING(s), 1, + PyBytes_GET_SIZE(s), fp); } else if (PyUnicode_Check(s)) { PyObject *t; @@ -301,8 +301,8 @@ internal_print(PyObject *op, FILE *fp, int flags, int nesting) if (t == NULL) ret = 0; else { - fwrite(PyString_AS_STRING(t), 1, - PyString_GET_SIZE(t), fp); + fwrite(PyBytes_AS_STRING(t), 1, + PyBytes_GET_SIZE(t), fp); } } else { @@ -1498,7 +1498,7 @@ _Py_ReadyTypes(void) if (PyType_Ready(&PyByteArray_Type) < 0) Py_FatalError("Can't initialize 'bytes'"); - if (PyType_Ready(&PyString_Type) < 0) + if (PyType_Ready(&PyBytes_Type) < 0) Py_FatalError("Can't initialize 'str'"); if (PyType_Ready(&PyList_Type) < 0) |