diff options
author | Antoine Pitrou <solipsis@pitrou.net> | 2010-01-13 08:07:53 (GMT) |
---|---|---|
committer | Antoine Pitrou <solipsis@pitrou.net> | 2010-01-13 08:07:53 (GMT) |
commit | f2c5484f9ee9c964454b2d4a176170042e3beea5 (patch) | |
tree | 56796a9587d43c252560bddc60ad864cbad0fa7a /Objects/stringlib/stringdefs.h | |
parent | 5efea0430caf2c6e066ae2f32e4c28f65d42d69a (diff) | |
download | cpython-f2c5484f9ee9c964454b2d4a176170042e3beea5.zip cpython-f2c5484f9ee9c964454b2d4a176170042e3beea5.tar.gz cpython-f2c5484f9ee9c964454b2d4a176170042e3beea5.tar.bz2 |
Merged revisions 77461 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk
........
r77461 | antoine.pitrou | 2010-01-13 08:55:48 +0100 (mer., 13 janv. 2010) | 5 lines
Issue #7622: Improve the split(), rsplit(), splitlines() and replace()
methods of bytes, bytearray and unicode objects by using a common
implementation based on stringlib's fast search. Patch by Florent Xicluna.
........
Diffstat (limited to 'Objects/stringlib/stringdefs.h')
-rw-r--r-- | Objects/stringlib/stringdefs.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/Objects/stringlib/stringdefs.h b/Objects/stringlib/stringdefs.h index 8a650fe..1c49426 100644 --- a/Objects/stringlib/stringdefs.h +++ b/Objects/stringlib/stringdefs.h @@ -11,6 +11,8 @@ #define STRINGLIB_TYPE_NAME "string" #define STRINGLIB_PARSE_CODE "S" #define STRINGLIB_EMPTY nullstring +#define STRINGLIB_ISSPACE Py_ISSPACE +#define STRINGLIB_ISLINEBREAK(x) ((x == '\n') || (x == '\r')) #define STRINGLIB_ISDECIMAL(x) ((x >= '0') && (x <= '9')) #define STRINGLIB_TODECIMAL(x) (STRINGLIB_ISDECIMAL(x) ? (x - '0') : -1) #define STRINGLIB_TOUPPER Py_TOUPPER |