Checks if C string p starts with needle.
the C string to check
the string to look for
true if p starts with needle
1 const buf = "123".toStaticArray; 2 const ptr = &buf[0]; 3 assert(ptr.startsWith("")); 4 assert(ptr.startsWith("1")); 5 assert(ptr.startsWith("12")); 6 assert(ptr.startsWith("123")); 7 assert(!ptr.startsWith("1234"));
See Implementation
Checks if C string p starts with needle.