From 051669b4cc2e127a5a0f0cb241e8af82bc6af5dc Mon Sep 17 00:00:00 2001 From: greg Date: Sun, 10 Mar 2019 17:24:58 -0700 Subject: [PATCH] Stuff pertaining to variant scoping --- schala-lang/language/src/symbol_table.rs | 3 +++ 1 file changed, 3 insertions(+) diff --git a/schala-lang/language/src/symbol_table.rs b/schala-lang/language/src/symbol_table.rs index 63a1560..db400be 100644 --- a/schala-lang/language/src/symbol_table.rs +++ b/schala-lang/language/src/symbol_table.rs @@ -178,6 +178,8 @@ impl SymbolTable { use crate::ast::{TypeIdentifier, Variant}; let TypeBody(variants) = body; let TypeSingletonName { name, .. } = type_name; + //scope_name_stack.push(name.clone()); //TODO adding this makes variants scoped under their + //type name and breaks a lot of things - don't add it until importing names works //TODO figure out why _params isn't being used here for (index, var) in variants.iter().enumerate() { match var { @@ -212,6 +214,7 @@ impl SymbolTable { }, } } + //scope_name_stack.pop(); Ok(()) } }