Line | Count | Source (jump to first uncovered line) |
1 | ||
2 | // | |
3 | // str-starts-with.c | |
4 | // | |
5 | // Copyright (c) 2013 Stephen Mathieson | |
6 | // MIT licensed | |
7 | // | |
8 | ||
9 | #include <stdbool.h> | |
10 | #include <string.h> | |
11 | #include "str-starts-with.h" | |
12 | ||
13 | 0 | bool str_starts_with(const char *str, const char *start) { |
14 | 0 | for (; ; str++, start++) |
15 | 0 | if (!*start) |
16 | 0 | return true; |
17 | 0 | else if (*str != *start) |
18 | 0 | return false; |
19 | 0 | } |