From 9f3edcbeea51dd8841b9d89fa7ef98f11682a1c7 Mon Sep 17 00:00:00 2001 From: Mustafa Quraish Date: Thu, 3 Feb 2022 21:01:03 -0500 Subject: Add support for basic structs Structs for now (and probably for the near future) are not allowed to be passed by value, and instead you just pass a pointer to it. Nested structs can also be defined, and they can be either anonymous, or named (in which case only the members can access the type). --- src/ast.c | 1 + 1 file changed, 1 insertion(+) (limited to 'src/ast.c') diff --git a/src/ast.c b/src/ast.c index 84aafca..62b8b6c 100644 --- a/src/ast.c +++ b/src/ast.c @@ -112,6 +112,7 @@ bool is_lvalue(NodeType type) { case AST_LOCAL_VAR: case AST_GLOBAL_VAR: + case OP_MEMBER: case OP_DEREF: // FIXME: Should this be the case? return true; default: return false; -- cgit v1.2.3