Bläddra i källkod

Fix to switch fix

Brian Fiete 4 år sedan
förälder
incheckning
a3ea79cd62
1 ändrade filer med 1 tillägg och 1 borttagningar
  1. 1 1
      IDEHelper/Compiler/BfStmtEvaluator.cpp

+ 1 - 1
IDEHelper/Compiler/BfStmtEvaluator.cpp

@@ -4464,7 +4464,7 @@ void BfModule::Visit(BfSwitchStatement* switchStmt)
 						}
 						}
 					}
 					}
 
 
-					if (caseValue.mType == switchValue.mType)
+					if ((caseValue.mType == switchValue.mType) || (eqResult))
 					{
 					{
 						constantInt = mBfIRBuilder->GetConstant(caseValue.mValue);
 						constantInt = mBfIRBuilder->GetConstant(caseValue.mValue);
 						if ((constantInt != NULL) && (!mBfIRBuilder->IsInt(constantInt->mTypeCode)))
 						if ((constantInt != NULL) && (!mBfIRBuilder->IsInt(constantInt->mTypeCode)))