1
0
mirror of https://git.lain.church/emil/libhl.git synced 2025-06-15 15:07:57 +00:00

globs and warning fixes

This commit is contained in:
Emil
2023-09-20 22:47:04 +00:00
parent 7983caee10
commit 3b7fb8dd10
6 changed files with 626 additions and 17 deletions

View File

@ -193,8 +193,8 @@ int token_fits(const token_t * const token,
return 0;
}
const int r = matches->width;
match_offset = matches->position;
const int r = matches->width;
*match_offset = matches->position;
free(matches);
@ -216,7 +216,7 @@ void render_string(const char * const string,
result_t * const r = (result_t *)malloc(sizeof(result_t) * 1024); // XXX: dont
int rrs = 0;
for (int i = 0; i < token_table.element_count; i++) {
for (size_t i = 0; i < token_table.element_count; i++) {
token_t * t = *(token_t**)vector_get(&token_table,
i);
match_t * match = regex_match(t->syntax, string, true);

View File

@ -1,4 +1,4 @@
#if __cplusplus
#ifdef __cplusplus
# pragma GCC diagnostic ignored "-Wc++20-extensions"
#endif