diff options
Diffstat (limited to 'clang/lib/CodeGen/CGDeclCXX.cpp')
| -rw-r--r-- | clang/lib/CodeGen/CGDeclCXX.cpp | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/clang/lib/CodeGen/CGDeclCXX.cpp b/clang/lib/CodeGen/CGDeclCXX.cpp index 0cc9330a866..742be0b25c6 100644 --- a/clang/lib/CodeGen/CGDeclCXX.cpp +++ b/clang/lib/CodeGen/CGDeclCXX.cpp @@ -90,7 +90,7 @@ static void EmitDeclDestroy(CodeGenFunction &CGF, const VarDecl &D, // Special-case non-array C++ destructors, where there's a function // with the right signature that we can just call. - const CXXRecordDecl *record = 0; + const CXXRecordDecl *record = nullptr; if (dtorKind == QualType::DK_cxx_destructor && (record = type->getAsCXXRecordDecl())) { assert(!record->hasTrivialDestructor()); @@ -305,7 +305,7 @@ CodeGenModule::EmitCXXGlobalVarDeclInitFunc(const VarDecl *D, if (I == DelayedCXXInitPosition.end()) { CXXGlobalInits.push_back(Fn); } else { - assert(CXXGlobalInits[I->second] == 0); + assert(CXXGlobalInits[I->second] == nullptr); CXXGlobalInits[I->second] = Fn; DelayedCXXInitPosition.erase(I); } @@ -313,7 +313,7 @@ CodeGenModule::EmitCXXGlobalVarDeclInitFunc(const VarDecl *D, } void CodeGenModule::EmitCXXThreadLocalInitFunc() { - llvm::Function *InitFn = 0; + llvm::Function *InitFn = nullptr; if (!CXXThreadLocalInits.empty()) { // Generate a guarded initialization function. llvm::FunctionType *FTy = llvm::FunctionType::get(VoidTy, false); @@ -420,7 +420,7 @@ void CodeGenFunction::GenerateCXXGlobalVarDeclInitFunc(llvm::Function *Fn, bool PerformInit) { // Check if we need to emit debug info for variable initializer. if (D->hasAttr<NoDebugAttr>()) - DebugInfo = NULL; // disable debug info indefinitely for this function + DebugInfo = nullptr; // disable debug info indefinitely for this function StartFunction(GlobalDecl(D), getContext().VoidTy, Fn, getTypes().arrangeNullaryFunction(), @@ -451,7 +451,7 @@ CodeGenFunction::GenerateCXXGlobalInitFunc(llvm::Function *Fn, // Emit an artificial location for this function. AL.Emit(); - llvm::BasicBlock *ExitBlock = 0; + llvm::BasicBlock *ExitBlock = nullptr; if (Guard) { // If we have a guard variable, check whether we've already performed // these initializations. This happens for TLS initialization functions. @@ -522,7 +522,7 @@ llvm::Function *CodeGenFunction::generateDestroyHelper( llvm::Constant *addr, QualType type, Destroyer *destroyer, bool useEHCleanupForArray, const VarDecl *VD) { FunctionArgList args; - ImplicitParamDecl dst(getContext(), 0, SourceLocation(), 0, + ImplicitParamDecl dst(getContext(), nullptr, SourceLocation(), nullptr, getContext().VoidPtrTy); args.push_back(&dst); |

