[llvm] r222386 - Try to fix MSVS build after r222384. No intended behavior change.
Mehdi Amini
mehdi.amini at apple.com
Wed Nov 19 22:44:39 PST 2014
Thanks for the fix. I did not know that MSVC choke on these, I’ll try to remember avoiding them in the future. I found the code less readable though :(
At least I would have broken “a" build on my first commit here ;)
Mehdi
> On Nov 19, 2014, at 1:16 PM, Nico Weber <nicolasweber at gmx.de> wrote:
>
> Author: nico
> Date: Wed Nov 19 15:16:11 2014
> New Revision: 222386
>
> URL: http://llvm.org/viewvc/llvm-project?rev=222386&view=rev
> Log:
> Try to fix MSVS build after r222384. No intended behavior change.
>
> Modified:
> llvm/trunk/lib/Transforms/Utils/SimplifyCFG.cpp
>
> Modified: llvm/trunk/lib/Transforms/Utils/SimplifyCFG.cpp
> URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Transforms/Utils/SimplifyCFG.cpp?rev=222386&r1=222385&r2=222386&view=diff
> ==============================================================================
> --- llvm/trunk/lib/Transforms/Utils/SimplifyCFG.cpp (original)
> +++ llvm/trunk/lib/Transforms/Utils/SimplifyCFG.cpp Wed Nov 19 15:16:11 2014
> @@ -377,8 +377,8 @@ static Value* GatherConstantComparesMatc
> // If this is an icmp against a constant, handle this as one of the cases.
> ICmpInst *ICI;
> ConstantInt *C;
> - if (not ((ICI = dyn_cast<ICmpInst>(I)) &&
> - (C = GetConstantInt(I->getOperand(1), DL)))) {
> + if (!((ICI = dyn_cast<ICmpInst>(I)) &&
> + (C = GetConstantInt(I->getOperand(1), DL)))) {
> return nullptr;
> }
>
> @@ -472,7 +472,7 @@ GatherConstantCompares(Value *V, SmallVe
> // Will hold the value used for the switch comparison
> Value *CurrValue = nullptr;
>
> - while(not DFT.empty()) {
> + while(!DFT.empty()) {
> V = DFT.pop_back_val();
>
> if (Instruction *I = dyn_cast<Instruction>(V)) {
>
>
> _______________________________________________
> llvm-commits mailing list
> llvm-commits at cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits
More information about the llvm-commits
mailing list