Function konst::string::starts_with
source · [−]Expand description
A const equivalent of
str::starts_with
, taking a &str
parameter.
Example
use konst::string;
assert!( string::starts_with("foo,bar,baz", "foo,"));
assert!(!string::starts_with("foo,bar,baz", "bar"));
assert!(!string::starts_with("foo,bar,baz", "baz"));