simplify code
authorChris Lattner <sabre@nondot.org>
Thu, 28 Sep 2006 22:58:25 +0000 (22:58 +0000)
committerChris Lattner <sabre@nondot.org>
Thu, 28 Sep 2006 22:58:25 +0000 (22:58 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30656 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Transforms/Utils/CodeExtractor.cpp

index 43324acf607e5a18a5a9eb749fea8dc05c4f93de..f264cff4722752140201c54a291b1bb624c48254 100644 (file)
@@ -470,7 +470,7 @@ emitCallAndSwitchStatement(Function *newFunction, BasicBlock *codeReplacer,
           case 0:
           case 1: break;  // No value needed.
           case 2:         // Conditional branch, return a bool
-            brVal = SuccNum ? ConstantBool::False : ConstantBool::True;
+            brVal = ConstantBool::get(!SuccNum);
             break;
           default:
             brVal = ConstantUInt::get(Type::UShortTy, SuccNum);