]> granicus.if.org Git - graphviz/commit
cgraph strview_str_contains: abbreviate prefix check
authorMatthew Fernandez <matthew.fernandez@gmail.com>
Sat, 15 Oct 2022 21:25:22 +0000 (14:25 -0700)
committerMatthew Fernandez <matthew.fernandez@gmail.com>
Thu, 3 Nov 2022 00:13:35 +0000 (17:13 -0700)
commit3567db13421cf993c661f2498a3b8c4cacf2b369
tree9a9fe15a4c324ae89e1b5ecfd81ba83f61f5171e
parent6a154d6b04ba00723435053bc169a105cbeb3ae6
cgraph strview_str_contains: abbreviate prefix check

After this function was written, the `startswith` helper was introduced for
abbreviating the idiom `strncmp(foo, bar, strlen(bar)) == 0`. We can use it to
more concisely and clearly express the intent of this code.
lib/cgraph/strview.h