diff options
author | Victor Stinner <victor.stinner@haypocalc.com> | 2012-02-24 23:47:08 (GMT) |
---|---|---|
committer | Victor Stinner <victor.stinner@haypocalc.com> | 2012-02-24 23:47:08 (GMT) |
commit | b0800dc53bdcb77b6fb7c07645460b7954792290 (patch) | |
tree | 6385534e79a199503c0c1008b26a4128ce92b14f | |
parent | abc649ddbe1894107218eb4a332a0476dab78a23 (diff) | |
download | cpython-b0800dc53bdcb77b6fb7c07645460b7954792290.zip cpython-b0800dc53bdcb77b6fb7c07645460b7954792290.tar.gz cpython-b0800dc53bdcb77b6fb7c07645460b7954792290.tar.bz2 |
Oops, revert unwanted changes
-rw-r--r-- | Objects/unicodeobject.c | 24 |
1 files changed, 6 insertions, 18 deletions
diff --git a/Objects/unicodeobject.c b/Objects/unicodeobject.c index d73145b..7cc6b1b 100644 --- a/Objects/unicodeobject.c +++ b/Objects/unicodeobject.c @@ -10628,10 +10628,7 @@ unicode_title(PyObject *self) { if (PyUnicode_READY(self) == -1) return NULL; - if (PyUnicode_IS_ASCII(self)) - return ascii_case_operation(self, ascii_do_title); - else - return case_operation(self, do_title); + return case_operation(self, do_title); } PyDoc_STRVAR(capitalize__doc__, @@ -10647,10 +10644,7 @@ unicode_capitalize(PyObject *self) return NULL; if (PyUnicode_GET_LENGTH(self) == 0) return unicode_result_unchanged(self); - if (PyUnicode_IS_ASCII(self)) - return ascii_case_operation(self, ascii_do_capitalize); - else - return case_operation(self, do_capitalize); + return case_operation(self, do_capitalize); } PyDoc_STRVAR(casefold__doc__, @@ -10665,8 +10659,7 @@ unicode_casefold(PyObject *self) return NULL; if (PyUnicode_IS_ASCII(self)) return ascii_upper_or_lower(self, 1); - else - return case_operation(self, do_casefold); + return case_operation(self, do_casefold); } @@ -11900,8 +11893,7 @@ unicode_lower(PyObject *self) return NULL; if (PyUnicode_IS_ASCII(self)) return ascii_upper_or_lower(self, 1); - else - return case_operation(self, do_lower); + return case_operation(self, do_lower); } #define LEFTSTRIP 0 @@ -12792,10 +12784,7 @@ unicode_swapcase(PyObject *self) { if (PyUnicode_READY(self) == -1) return NULL; - if (PyUnicode_IS_ASCII(self)) - return ascii_case_operation(self, ascii_do_swapcase); - else - return case_operation(self, do_swapcase); + return case_operation(self, do_swapcase); } PyDoc_STRVAR(maketrans__doc__, @@ -12945,8 +12934,7 @@ unicode_upper(PyObject *self) return NULL; if (PyUnicode_IS_ASCII(self)) return ascii_upper_or_lower(self, 0); - else - return case_operation(self, do_upper); + return case_operation(self, do_upper); } PyDoc_STRVAR(zfill__doc__, |