STINNER Victor added the comment:

Hum, it's a regression introduced by the super-optimized fastsearch. It is just 
a typo: _s => s. I renamed _s to ptr to avoid future confusion ;-)

--

For your information, str.find(), str.rfind(), str.index(), str.rindex() and 
str.replace() are now using memchr() and memrchr() to find a substring, even if 
the substring contains characters outside the ASCII (U+0000-U+007F) and latin1 
ranges (U+0000-U+00FF). memchr() and memrchr() are much faster than a dummy C 
loop, even if there are false positive.

----------
keywords: +patch
nosy: +flox, haypo, loewis, pitrou
Added file: http://bugs.python.org/file26661/fastsearch.patch

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue15534>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to