Skip to content

Commit

Permalink
fixed makename -> makelabel
Browse files Browse the repository at this point in the history
  • Loading branch information
EthanSK committed Mar 26, 2019
1 parent e192fab commit fc07a93
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/ast/conditions/switch/switchStatement.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ void SwitchStatement::generateIL(std::vector<Instr> &instrs, ILContext &context,
{
ScopeBlockPtr switchBlock = Utils::tryCast<ScopeBlock>(getSwitchBlock(), "switch block must be a scope block"); //just to get access to branches
std::vector<StatementPtr> switchBlockBranches = switchBlock->getBranches();
std::string switchEnd_lb = context.makeName("switchEnd"); //the a in switch (a)
std::string switchEnd_lb = context.makeLabelName("switchEnd"); //the a in switch (a)
context.pushLoopLabels("NULL", switchEnd_lb);

//we could set up labels and scope blocks first, the branch past all that, then beq back...nah would mess up at the end.
Expand Down

0 comments on commit fc07a93

Please sign in to comment.