xxxxxxxxxx
bool startsWith(scope const(char)[] haystack,
scope const(char)[] needle) pure
{
if (haystack.length >= needle.length)
{
return haystack[0 .. needle.length] == needle; // is slice range checking avoid here?
}
return false;
}