Commit 8ce92a59 by Andrew Dahl

Fixed 'make debug' to deal with the new vector pointer for yyparse

parent ccc3ff42
Showing with 5 additions and 5 deletions
......@@ -11,7 +11,7 @@
#include <vector>
#include "../include/symbolTable.h"
#include "../include/instructionList.h"
int yyparse (vector<SymbolTable*> symbol_table, InstructionList* instructions);
int yyparse (vector<SymbolTable*>* symbol_table, InstructionList* instructions);
#endif
using namespace std;
......@@ -27,10 +27,10 @@ int main(int argc, char *argv[]) {
}
#else
InstructionList* instructions = new InstructionList();
vector<SymbolTable*> symbol_table;
symbol_table.push_back(new SymbolTable());
symbol_table[0]->Insert(new Symbol("readInput", Symbol::INPUT, Symbol::INTEGER));
symbol_table.push_back(new SymbolTable(0, symbol_table[0]));
vector<SymbolTable*>* symbol_table = new vector<SymbolTable*>();
symbol_table->push_back(new SymbolTable());
symbol_table->at(0)->Insert(new Symbol("readInput", Symbol::INPUT, Symbol::INTEGER));
symbol_table->push_back(new SymbolTable(0, symbol_table->at(0)));
yyparse(symbol_table, instructions);
#endif
return 0;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment