Hi Antoine, > changeset: 701b2e0e6f3f > user: Antoine Pitrou <solipsis at pitrou.net> > date: Thu Oct 13 18:07:37 2011 +0200 > summary: > Add a comment explaining this heuristic. > > diff --git a/Objects/stringlib/fastsearch.h b/Objects/stringlib/fastsearch.h > --- a/Objects/stringlib/fastsearch.h > +++ b/Objects/stringlib/fastsearch.h > @@ -115,6 +115,9 @@ > unsigned char needle; > needle = p[0] & 0xff; > #if STRINGLIB_SIZEOF_CHAR > 1 > + /* If looking for a multiple of 256, we'd have two > + many false positives looking for the '\0' byte in UCS2 > + and UCS4 representations. */ I guess this should read “too many”, not “two”. Cheers
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4