fix: review problems
This commit is contained in:
@@ -5,8 +5,6 @@
|
||||
#include <stdbool.h>
|
||||
#include <stdio.h>
|
||||
|
||||
char c_problem[256];
|
||||
|
||||
// Analyze class construct
|
||||
fzl_an_res_t analyze_construct(fzl_analyzer_t *analyzer, fzl_node_t *construct)
|
||||
{
|
||||
@@ -15,7 +13,7 @@ fzl_an_res_t analyze_construct(fzl_analyzer_t *analyzer, fzl_node_t *construct)
|
||||
|
||||
if (!construct || construct->type != FZL_NODETYPE_CONSTRUCT)
|
||||
{
|
||||
an_push_error(analyzer, NULL, "node is not typeof CONSTRUCT");
|
||||
an_push_error(analyzer, NULL, "node is not a construct");
|
||||
return (fzl_an_res_t){.error = true};
|
||||
}
|
||||
|
||||
@@ -30,8 +28,8 @@ fzl_an_res_t analyze_construct(fzl_analyzer_t *analyzer, fzl_node_t *construct)
|
||||
|
||||
if (!sym_found)
|
||||
{
|
||||
snprintf(c_problem, sizeof(c_problem), "class '%s' not found", classname);
|
||||
an_push_error(analyzer, construct->token, c_problem);
|
||||
snprintf(an_problem, sizeof(an_problem), "class '%s' not found", classname);
|
||||
an_push_error(analyzer, construct->token, an_problem);
|
||||
return (fzl_an_res_t){.error = true};
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user