Edit pass over changes before merge.

This commit is contained in:
Robin Sommer 2019-07-18 23:07:34 +00:00
parent 004347b853
commit 1bf0cd29fd
14 changed files with 312 additions and 298 deletions

View file

@ -29,6 +29,14 @@ extern void end_func(Stmt* body);
extern std::unique_ptr<function_ingredients> gather_function_ingredients(Stmt* body);
extern std::shared_ptr<id_list> gather_outer_ids(Scope* scope, Stmt* body);
// Gathers all of the information from a scope and a function body needed to
// build a function and collects it into a function_ingredients struct.
// Gathered elements are not refeed.
extern std::unique_ptr<function_ingredients> gather_function_ingredients(Scope* scope, Stmt* body);
// Gather all IDs referenced inside a body that aren't part of a given scope.
extern std::shared_ptr<id_list> gather_outer_ids(Scope* scope, Stmt* body);
extern Val* internal_val(const char* name);
extern Val* internal_const_val(const char* name); // internal error if not const
extern Val* opt_internal_val(const char* name); // returns nil if not defined