summaryrefslogtreecommitdiff
path: root/lib/CodeGen/AsmPrinter/DwarfException.cpp
diff options
context:
space:
mode:
authorCraig Topper <craig.topper@gmail.com>2014-04-24 06:44:33 +0000
committerCraig Topper <craig.topper@gmail.com>2014-04-24 06:44:33 +0000
commite703fcb9757820fe27d9ef98ce3775d9c6d6e898 (patch)
tree723280dd6234fa80ce8d001b0e09378ca717f6c9 /lib/CodeGen/AsmPrinter/DwarfException.cpp
parent2c0470e781355a96f901fcf863f59b814eac20fa (diff)
downloadllvm-e703fcb9757820fe27d9ef98ce3775d9c6d6e898.tar.gz
llvm-e703fcb9757820fe27d9ef98ce3775d9c6d6e898.tar.bz2
llvm-e703fcb9757820fe27d9ef98ce3775d9c6d6e898.tar.xz
[C++] Use 'nullptr'.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@207083 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/AsmPrinter/DwarfException.cpp')
-rw-r--r--lib/CodeGen/AsmPrinter/DwarfException.cpp14
1 files changed, 7 insertions, 7 deletions
diff --git a/lib/CodeGen/AsmPrinter/DwarfException.cpp b/lib/CodeGen/AsmPrinter/DwarfException.cpp
index 113a9e4cd4..282a1bf5b4 100644
--- a/lib/CodeGen/AsmPrinter/DwarfException.cpp
+++ b/lib/CodeGen/AsmPrinter/DwarfException.cpp
@@ -103,7 +103,7 @@ ComputeActionsTable(const SmallVectorImpl<const LandingPadInfo*> &LandingPads,
int FirstAction = 0;
unsigned SizeActions = 0;
- const LandingPadInfo *PrevLPI = 0;
+ const LandingPadInfo *PrevLPI = nullptr;
for (SmallVectorImpl<const LandingPadInfo *>::const_iterator
I = LandingPads.begin(), E = LandingPads.end(); I != E; ++I) {
@@ -181,7 +181,7 @@ bool DwarfException::CallToNoUnwindFunction(const MachineInstr *MI) {
if (!MO.isGlobal()) continue;
const Function *F = dyn_cast<Function>(MO.getGlobal());
- if (F == 0) continue;
+ if (!F) continue;
if (SawFunc) {
// Be conservative. If we have more than one function operand for this
@@ -214,7 +214,7 @@ ComputeCallSiteTable(SmallVectorImpl<CallSiteEntry> &CallSites,
const SmallVectorImpl<const LandingPadInfo *> &LandingPads,
const SmallVectorImpl<unsigned> &FirstActions) {
// The end label of the previous invoke or nounwind try-range.
- MCSymbol *LastLabel = 0;
+ MCSymbol *LastLabel = nullptr;
// Whether there is a potentially throwing instruction (currently this means
// an ordinary call) between the end of the previous try-range and now.
@@ -255,7 +255,7 @@ ComputeCallSiteTable(SmallVectorImpl<CallSiteEntry> &CallSites,
// create a call-site entry with no landing pad for the region between the
// try-ranges.
if (SawPotentiallyThrowing && Asm->MAI->isExceptionHandlingDwarf()) {
- CallSiteEntry Site = { LastLabel, BeginLabel, 0, 0 };
+ CallSiteEntry Site = { LastLabel, BeginLabel, nullptr, 0 };
CallSites.push_back(Site);
PreviousIsInvoke = false;
}
@@ -305,7 +305,7 @@ ComputeCallSiteTable(SmallVectorImpl<CallSiteEntry> &CallSites,
// function may throw, create a call-site entry with no landing pad for the
// region following the try-range.
if (SawPotentiallyThrowing && Asm->MAI->isExceptionHandlingDwarf()) {
- CallSiteEntry Site = { LastLabel, 0, 0, 0 };
+ CallSiteEntry Site = { LastLabel, nullptr, nullptr, 0 };
CallSites.push_back(Site);
}
}
@@ -571,10 +571,10 @@ void DwarfException::EmitExceptionTable() {
Asm->GetTempSymbol("eh_func_begin", Asm->getFunctionNumber());
MCSymbol *BeginLabel = S.BeginLabel;
- if (BeginLabel == 0)
+ if (!BeginLabel)
BeginLabel = EHFuncBeginSym;
MCSymbol *EndLabel = S.EndLabel;
- if (EndLabel == 0)
+ if (!EndLabel)
EndLabel = Asm->GetTempSymbol("eh_func_end", Asm->getFunctionNumber());