summaryrefslogtreecommitdiff
path: root/include/parser/var.h
diff options
context:
space:
mode:
authorQuinn Stephens <quinn@osmora.org>2024-11-03 19:12:47 -0500
committerQuinn Stephens <quinn@osmora.org>2024-11-03 19:12:47 -0500
commit063c40584ae78a396b558a5e2a08e3d871450c0b (patch)
tree1acca2d57ba421530b1cfd2a23f0658e35e7ebae /include/parser/var.h
parent71b10c1c765196a771ce05216395d6b78892a735 (diff)
[compiler] Parse and print procedure declarations
Signed-off-by: Quinn Stephens <quinn@osmora.org>
Diffstat (limited to 'include/parser/var.h')
-rw-r--r--include/parser/var.h24
1 files changed, 24 insertions, 0 deletions
diff --git a/include/parser/var.h b/include/parser/var.h
new file mode 100644
index 0000000..dd981f5
--- /dev/null
+++ b/include/parser/var.h
@@ -0,0 +1,24 @@
+/*
+ * Variable definitions.
+ * Copyright (c) 2023-2024, Quinn Stephens and the OSMORA team.
+ * Provided under the BSD 3-Clause license.
+ */
+
+#ifndef _PARSER_VAR_H
+#define _PARSER_VAR_H
+
+#include <stddef.h>
+#include "hashmap.h"
+#include "parser/type.h"
+
+struct variable {
+ struct hashmap_entry hashmap_entry;
+
+ char *name;
+ size_t name_len;
+
+ struct type *typ;
+ int n_ptrs;
+};
+
+#endif /* !_PARSER_VAR_H */