aboutsummaryrefslogtreecommitdiff
path: root/src/parser/ast.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/parser/ast.h')
-rw-r--r--src/parser/ast.h11
1 files changed, 11 insertions, 0 deletions
diff --git a/src/parser/ast.h b/src/parser/ast.h
index 7079305..30dd1e7 100644
--- a/src/parser/ast.h
+++ b/src/parser/ast.h
@@ -10,13 +10,24 @@ struct ConstDecl
struct Token value;
};
+struct DataDecl
+{
+ struct Token name;
+ struct Token value;
+};
+
struct Program
{
struct ConstDecl* consts;
size_t const_count;
size_t const_capacity;
+
+ struct DataDecl* data_decls;
+ size_t data_count;
+ size_t data_capacity;
};
struct Program create_program(void);
void free_program(struct Program* program);
void add_const(struct Program* program, struct ConstDecl decl);
+void add_data(struct Program* program, struct DataDecl decl);