From b64d16088b29615d222d33450cf0315467400e59 Mon Sep 17 00:00:00 2001 From: Patrick Schönberger Date: Thu, 29 Jul 2021 09:58:14 +0200 Subject: toc now uses internal representation instead of ast --- src/main.cpp | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'src/main.cpp') diff --git a/src/main.cpp b/src/main.cpp index a7742ac..7d8d5c7 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -32,12 +32,6 @@ int main(int argc, const char * argv[]) { //std::cout << "Parse Tree: " << s << std::endl; - //toc(std::cout, prog); - - //std::ofstream ofs("output.c"); - //toc(ofs, prog); - //ofs.close(); - Program prg = getProgram(prog); std::cout << "Variables:\n"; for (auto v : prg.variables) @@ -46,5 +40,11 @@ int main(int argc, const char * argv[]) { for (auto f : prg.functions) std::cout << " " << f.name << endl; + tocProgram(std::cout, prg); + + //std::ofstream ofs("output.c"); + //tocProg(ofs, prg); + //ofs.close(); + return 0; } \ No newline at end of file -- cgit v1.2.3