From e29aa52460df6a5d3e78f7e466947bcdd7a3bbb0 Mon Sep 17 00:00:00 2001 From: Bruce Hill Date: Mon, 4 Mar 2024 13:51:47 -0500 Subject: Struct and enum methods and static members --- environment.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'environment.h') diff --git a/environment.h b/environment.h index 47d1dea2..8660fe68 100644 --- a/environment.h +++ b/environment.h @@ -20,6 +20,7 @@ typedef struct { table_t *types, *globals, *locals; table_t *type_namespaces; // Map of type name -> namespace table compilation_unit_t *code; + CORD scope_prefix; } env_t; typedef struct { @@ -29,6 +30,7 @@ typedef struct { env_t *new_compilation_unit(void); env_t *fresh_scope(env_t *env); +env_t *namespace_env(env_t *env, const char *namespace_name); __attribute__((noreturn)) void compiler_err(file_t *f, const char *start, const char *end, const char *fmt, ...); binding_t *get_binding(env_t *env, const char *name); -- cgit v1.2.3