Skip to content

Commit 3eff7b8

Browse files
committed
leave optimization to the compiler
1 parent b585bf0 commit 3eff7b8

File tree

1 file changed

+0
-4
lines changed

1 file changed

+0
-4
lines changed

Python/codecs.c

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -908,10 +908,6 @@ PyObject *PyCodec_BackslashReplaceErrors(PyObject *exc)
908908
return NULL;
909909
}
910910

911-
if (slen == 0) { // end <= start
912-
Py_DECREF(obj);
913-
return Py_BuildValue("(Nn)", Py_GetConstant(Py_CONSTANT_EMPTY_STR), end);
914-
}
915911
if (slen > PY_SSIZE_T_MAX / 10) {
916912
end = start + PY_SSIZE_T_MAX / 10;
917913
end = Py_MIN(end, objlen);

0 commit comments

Comments
 (0)