refactor: moved ast module to utils

This commit is contained in:
Gu://em_ 2026-01-09 16:05:41 +01:00
parent 0f484b371b
commit 3e66d4b959
3 changed files with 0 additions and 0 deletions

37
src/utils/ast/ast.h Normal file
View file

@ -0,0 +1,37 @@
#ifndef AST_H
#define AST_H
#include "lists.h"
enum ast_type
{
AST_END = 0,
AST_IF,
AST_CMD
};
union ast_node
{
struct ast_if;
struct ast_cmd;
};
struct ast
{
enum ast_type type;
union ast_node data;
};
struct ast_if
{
struct ast* condition;
struct ast* then_clause;
struct ast* else_clause;
};
struct ast_cmd
{
struct list* cmd;
};
#endif /* ! AST_H */