clang-tidy: apply modern-use-nullptr fixes
Instead of using 0 or NULL use the C++11 nullptr symbol when referencing null
pointers.
This cleanup was suggested by Eugene Zelenko <eugene.zelenko@gmail.com> in
http://reviews.llvm.org/D21488 and was split out to increase readability.
llvm-svn: 273435
diff --git a/polly/lib/CodeGen/LoopGenerators.cpp b/polly/lib/CodeGen/LoopGenerators.cpp
index 566e460..149cf2c 100644
--- a/polly/lib/CodeGen/LoopGenerators.cpp
+++ b/polly/lib/CodeGen/LoopGenerators.cpp
@@ -289,7 +289,7 @@
BasicBlock &EntryBB = Builder.GetInsertBlock()->getParent()->getEntryBlock();
Instruction *IP = &*EntryBB.getFirstInsertionPt();
StructType *Ty = StructType::get(Builder.getContext(), Members);
- AllocaInst *Struct = new AllocaInst(Ty, 0, "polly.par.userContext", IP);
+ AllocaInst *Struct = new AllocaInst(Ty, nullptr, "polly.par.userContext", IP);
// Mark the start of the lifetime for the parameter struct.
ConstantInt *SizeOf = Builder.getInt64(DL.getTypeAllocSize(Ty));
@@ -338,8 +338,8 @@
// Fill up basic block HeaderBB.
Builder.SetInsertPoint(HeaderBB);
- LBPtr = Builder.CreateAlloca(LongType, 0, "polly.par.LBPtr");
- UBPtr = Builder.CreateAlloca(LongType, 0, "polly.par.UBPtr");
+ LBPtr = Builder.CreateAlloca(LongType, nullptr, "polly.par.LBPtr");
+ UBPtr = Builder.CreateAlloca(LongType, nullptr, "polly.par.UBPtr");
UserContext = Builder.CreateBitCast(
&*SubFn->arg_begin(), StructData->getType(), "polly.par.userContext");