connorjacobsen / iris

The Iris programming language
MIT License
8 stars 1 forks source link

Env list nesting #7

Open connorjacobsen opened 8 years ago

connorjacobsen commented 8 years ago

Need some mechanism for nesting Envs. This will make it easier to maintain correct symbol tables for functions, namespaces, modules, etc.

Can probably just use a list for this. New environments get appended to the list, with name resolution starting at the end of the list and working towards the front. Or new environments getting prepended to the list and name resolution starting from the head of the list, whichever is simpler to implement is fine, as its essentially the same idea.