diff options
author | kartofen <mladenovnasko0@gmail.com> | 2025-07-09 17:23:04 +0300 |
---|---|---|
committer | kartofen <mladenovnasko0@gmail.com> | 2025-07-09 17:23:04 +0300 |
commit | 2c85f2d087b9b2f3922b856beed4e2dd5b0fc126 (patch) | |
tree | 49de0cef8eb32596f2629e3d2855400484fbd8aa /parts | |
parent | e911e95f697b0eb48ed4e68cb2586ffb0dc11341 (diff) |
edit readme
Diffstat (limited to 'parts')
-rw-r--r-- | parts/grammar.h | 4 | ||||
-rw-r--r-- | parts/symbol.h | 2 | ||||
-rw-r--r-- | parts/table.h | 2 |
3 files changed, 8 insertions, 0 deletions
diff --git a/parts/grammar.h b/parts/grammar.h index a02a99e..d1bf176 100644 --- a/parts/grammar.h +++ b/parts/grammar.h @@ -1,6 +1,8 @@ #ifndef GRAMMAR_H #define GRAMMAR_H +#include <stddef.h> // size_t + extern struct production { symbol LHS; symbol *RHS; @@ -9,6 +11,8 @@ extern struct production { extern size_t total_productions; +#include <stdio.h> + void grammar_print() { for(size_t i = 0; i < total_productions; i++) { diff --git a/parts/symbol.h b/parts/symbol.h index e5e45d3..2190eca 100644 --- a/parts/symbol.h +++ b/parts/symbol.h @@ -1,6 +1,8 @@ #ifndef SYMBOL_H #define SYMBOL_H +#include <stddef.h> // size_t + typedef unsigned int symbol; extern size_t total_symbols; extern char **symbol_to_str; diff --git a/parts/table.h b/parts/table.h index fc63488..f3099fe 100644 --- a/parts/table.h +++ b/parts/table.h @@ -1,6 +1,8 @@ #ifndef TABLE_H #define TABLE_H +#include <stddef.h> // size_t + extern struct action { enum action_type { ACTION_NOT_SET = 0, ACTION_SHIFT, |