[Python-Dev] [Python-checkins] cpython: Fix PyUnicode_Substring() for start >= length and start (original) (raw)
Victor Stinner victor.stinner at gmail.com
Thu May 3 03:38:33 CEST 2012
- Previous message: [Python-Dev] [Python-checkins] cpython: Fix PyUnicode_Substring() for start >= length and start > end
- Next message: [Python-Dev] CRLF line endings
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
+ if (start >= length || end < start) { + assert(end == length); + return PyUnicodeNew(0, 0); + } That assert doesn't look right.
Oh, you're right. I added it for the first case: start>=length. But the assertion is really useless, I removed it. Thanks!
Victor
- Previous message: [Python-Dev] [Python-checkins] cpython: Fix PyUnicode_Substring() for start >= length and start > end
- Next message: [Python-Dev] CRLF line endings
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]