1
0
Fork 0
mirror of https://github.com/beefytech/Beef.git synced 2025-06-08 19:48:20 +02:00

Switch fix

This commit is contained in:
Brian Fiete 2020-09-06 10:26:39 -07:00
parent a7acc5ebb3
commit 27e2ed1598

View file

@ -4128,9 +4128,7 @@ void BfModule::Visit(BfSwitchStatement* switchStmt)
newScope.mInnerIsConditional = true; newScope.mInnerIsConditional = true;
newScope.mCloseNode = switchStmt; newScope.mCloseNode = switchStmt;
if (switchStmt->mCloseBrace != NULL) if (switchStmt->mCloseBrace != NULL)
newScope.mCloseNode = switchStmt->mCloseBrace; newScope.mCloseNode = switchStmt->mCloseBrace;
if (switchStmt->mLabelNode != NULL)
newScope.mLabelNode = switchStmt->mLabelNode->mLabel;
mCurMethodState->AddScope(&newScope); mCurMethodState->AddScope(&newScope);
NewScopeState(); NewScopeState();