feat: add prepared error/null ok returns from gen_* functions

This commit is contained in:
samsonium
2026-11-04 22:52:40 +03:00
parent aae183c0c0
commit 181458ecda
18 changed files with 232 additions and 66 deletions
+2 -2
View File
@@ -7,11 +7,11 @@
gen_res_t gen_fmtstr(fzl_gen_t *gen, fzl_node_t *node)
{
if (!gen || !node)
return (gen_res_t){.error = true};
return gen_error;
for (size_t i = 0; i < node->list.entry_count; i++)
if (gen_common(gen, node->list.entries[i]).error)
return (gen_res_t){.error = true};
return gen_error;
gen_op(gen, FZL_OPCODE_BUILD_STR);
gen_word(gen, node->list.entry_count);