D-Programming-Language/phobos — pull request #1486 by tom-tan (2013-08-17 15:35:11+00:00)
Title: Make std.string.indexOf @safe

`indexOf` only accepts built-in string types.
It uses unsafe function `core.stdc.string.memchr` but it does not touch the memory over the length of the string.

I do not mark the unittests for it as safe because it uses `core.stdc.stdio.printf` which is an unsafe function.