From 4ab3631aadcd27df708a16f6bf22953e0ff9b1cf Mon Sep 17 00:00:00 2001 From: pommicket Date: Sat, 5 Aug 2023 13:55:53 -0400 Subject: internalize Line structure --- tags.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'tags.c') diff --git a/tags.c b/tags.c index 16c005a..95f5e5b 100644 --- a/tags.c +++ b/tags.c @@ -325,8 +325,8 @@ top:; pcre2_match_data *match_data = pcre2_match_data_create(10, NULL); if (match_data) { for (u32 line_idx = 0; line_idx < buffer->nlines; ++line_idx) { - Line *line = &buffer->lines[line_idx]; - int n = pcre2_match(code, line->str, line->len, 0, PCRE2_NOTEMPTY, + String32 line = buffer_get_line(buffer, line_idx); + int n = pcre2_match(code, line.str, line.len, 0, PCRE2_NOTEMPTY, match_data, NULL); if (n == 1) { // found it! -- cgit v1.2.3