replace uses of AssocList with Dictionary (#344)

Co-authored-by: Geoff Romer <gromer@google.com>
Co-authored-by: Dave Abrahams <dabrahams@google.com>
This commit is contained in:
Jeremy G. Siek
2021-03-06 08:06:05 -08:00
committed by GitHub
co-authored by Geoff Romer Dave Abrahams
parent 5d6593ee39
commit 05db2012ab
9 changed files with 185 additions and 172 deletions
@@ -28,9 +28,9 @@ void ExecProgram(std::list<Declaration>* fs) {
std::cout << "********** type checking **********" << std::endl;
}
state = new State(); // Compile-time state.
std::pair<TypeEnv*, Env*> p = TopLevel(fs);
TypeEnv* top = p.first;
Env* ct_top = p.second;
std::pair<TypeEnv, Env> p = TopLevel(fs);
TypeEnv top = p.first;
Env ct_top = p.second;
std::list<Declaration> new_decls;
for (const auto& decl : *fs) {
new_decls.push_back(decl.TypeChecked(top, ct_top));