diff options
| author | Fredrik Lundh <fredrik@pythonware.com> | 2006-05-26 19:24:53 (GMT) |
|---|---|---|
| committer | Fredrik Lundh <fredrik@pythonware.com> | 2006-05-26 19:24:53 (GMT) |
| commit | 58b5e84d52bc15ff1cae26ecff36e5a99d6715b6 (patch) | |
| tree | 0884631f9ac8578ce1c94c6fa372494265524ba8 /Objects/stringlib/partition.h | |
| parent | a26de2a80fce5070155b3facb126c176988f4513 (diff) | |
| download | cpython-58b5e84d52bc15ff1cae26ecff36e5a99d6715b6.zip cpython-58b5e84d52bc15ff1cae26ecff36e5a99d6715b6.tar.gz cpython-58b5e84d52bc15ff1cae26ecff36e5a99d6715b6.tar.bz2 | |
needforspeed: stringlib refactoring, continued. added count and
find helpers; updated unicodeobject to use stringlib_count
Diffstat (limited to 'Objects/stringlib/partition.h')
| -rw-r--r-- | Objects/stringlib/partition.h | 16 |
1 files changed, 12 insertions, 4 deletions
diff --git a/Objects/stringlib/partition.h b/Objects/stringlib/partition.h index 71e80a9..8cc7abe 100644 --- a/Objects/stringlib/partition.h +++ b/Objects/stringlib/partition.h @@ -3,9 +3,15 @@ #ifndef STRINGLIB_PARTITION_H #define STRINGLIB_PARTITION_H +#ifndef STRINGLIB_FASTSEARCH_H +#error must include "stringlib/fastsearch.h" before including this module +#endif + Py_LOCAL(PyObject*) -partition(PyObject* str_obj, const STRINGLIB_CHAR* str, Py_ssize_t str_len, - PyObject* sep_obj, const STRINGLIB_CHAR* sep, Py_ssize_t sep_len) +stringlib_partition( + PyObject* str_obj, const STRINGLIB_CHAR* str, Py_ssize_t str_len, + PyObject* sep_obj, const STRINGLIB_CHAR* sep, Py_ssize_t sep_len + ) { PyObject* out; Py_ssize_t pos; @@ -46,8 +52,10 @@ partition(PyObject* str_obj, const STRINGLIB_CHAR* str, Py_ssize_t str_len, } Py_LOCAL(PyObject*) -rpartition(PyObject* str_obj, const STRINGLIB_CHAR* str, Py_ssize_t str_len, - PyObject* sep_obj, const STRINGLIB_CHAR* sep, Py_ssize_t sep_len) +stringlib_rpartition( + PyObject* str_obj, const STRINGLIB_CHAR* str, Py_ssize_t str_len, + PyObject* sep_obj, const STRINGLIB_CHAR* sep, Py_ssize_t sep_len + ) { PyObject* out; Py_ssize_t pos; |
