From c72b0406a32ffc3f04324f7b6c321486762fca41 Mon Sep 17 00:00:00 2001 From: Bruce Hill Date: Sat, 16 Aug 2025 17:21:01 -0400 Subject: Improved parsing and prefix/suffix matching using a `remainder` parameter --- src/tomo.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/tomo.c') diff --git a/src/tomo.c b/src/tomo.c index f60e7427..e105cb7a 100644 --- a/src/tomo.c +++ b/src/tomo.c @@ -709,11 +709,11 @@ time_t latest_included_modification_time(Path_t path) bool allow_dot_include = Path$has_extension(path, Text("s")) || Path$has_extension(path, Text("S")); for (Text_t line; (line=next_line(by_line.userdata)).length >= 0; ) { line = Text$trim(line, Text(" \t"), true, false); - if (!Text$starts_with(line, Text("#include")) && !(allow_dot_include && Text$starts_with(line, Text(".include")))) + if (!Text$starts_with(line, Text("#include"), NULL) && !(allow_dot_include && Text$starts_with(line, Text(".include"), NULL))) continue; // Check for `"` after `#include` or `.include` and some spaces: - if (!Text$starts_with(Text$trim(Text$from(line, I(9)), Text(" \t"), true, false), Text("\""))) + if (!Text$starts_with(Text$trim(Text$from(line, I(9)), Text(" \t"), true, false), Text("\""), NULL)) continue; List_t chunks = Text$split(line, Text("\"")); -- cgit v1.2.3