* Fixes #12187
* Point to fork of compactdict
Since the original repo is now archived / read-only
This commit is contained in:
Clyybber 2019-10-08 14:15:47 +02:00 • committed by Andreas Rumpf
commit 00c31e8766
11 changed files with 44 additions and 21 deletions

View file

@ -1872,7 +1872,7 @@ proc find*(s: string, sub: char, start: Natural = 0, last = 0): int {.noSideEffe
when hasCStringBuiltin:
let L = last-start+1
if L > 0:
let found = c_memchr(s[start].unsafeAddr, sub, L)
let found = c_memchr(s[start].unsafeAddr, sub, csize L)
if not found.isNil:
return cast[ByteAddress](found) -% cast[ByteAddress](s.cstring)
else: