From 570e52c6f17d8819ee4c8595fc79d17a6dc51dd9 Mon Sep 17 00:00:00 2001 From: Craig Topper Date: Tue, 15 Apr 2014 04:59:12 +0000 Subject: [C++11] More 'nullptr' conversion. In some cases just using a boolean check instead of comparing to nullptr. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@206243 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/Analysis/Analysis.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'lib/Analysis/Analysis.cpp') diff --git a/lib/Analysis/Analysis.cpp b/lib/Analysis/Analysis.cpp index c960123d08..01c1c7e572 100644 --- a/lib/Analysis/Analysis.cpp +++ b/lib/Analysis/Analysis.cpp @@ -73,7 +73,7 @@ void LLVMInitializeAnalysis(LLVMPassRegistryRef R) { LLVMBool LLVMVerifyModule(LLVMModuleRef M, LLVMVerifierFailureAction Action, char **OutMessages) { - raw_ostream *DebugOS = Action != LLVMReturnStatusAction ? &errs() : 0; + raw_ostream *DebugOS = Action != LLVMReturnStatusAction ? &errs() : nullptr; std::string Messages; raw_string_ostream MsgsOS(Messages); @@ -94,7 +94,8 @@ LLVMBool LLVMVerifyModule(LLVMModuleRef M, LLVMVerifierFailureAction Action, LLVMBool LLVMVerifyFunction(LLVMValueRef Fn, LLVMVerifierFailureAction Action) { LLVMBool Result = verifyFunction( - *unwrap(Fn), Action != LLVMReturnStatusAction ? &errs() : 0); + *unwrap(Fn), Action != LLVMReturnStatusAction ? &errs() + : nullptr); if (Action == LLVMAbortProcessAction && Result) report_fatal_error("Broken function found, compilation aborted!"); -- cgit v1.2.3