X-Git-Url: http://plrg.eecs.uci.edu/git/?a=blobdiff_plain;f=include%2Fllvm%2FPassAnalysisSupport.h;h=9164305418092385d0613c3ca238ca014ca7397f;hb=4becee113cc07d89a29c7fa7cb3b353635079315;hp=c11ca0bbdedcb619b788eb17c51dbae93a18270e;hpb=7e2c793a2b5c746344652b6579e958ee42fafdcc;p=oota-llvm.git diff --git a/include/llvm/PassAnalysisSupport.h b/include/llvm/PassAnalysisSupport.h index c11ca0bbded..91643054180 100644 --- a/include/llvm/PassAnalysisSupport.h +++ b/include/llvm/PassAnalysisSupport.h @@ -16,12 +16,12 @@ // //===----------------------------------------------------------------------===// -#ifndef LLVM_PASS_ANALYSIS_SUPPORT_H -#define LLVM_PASS_ANALYSIS_SUPPORT_H +#ifndef LLVM_PASSANALYSISSUPPORT_H +#define LLVM_PASSANALYSISSUPPORT_H -#include "llvm/Pass.h" #include "llvm/ADT/SmallVector.h" #include "llvm/ADT/StringRef.h" +#include "llvm/Pass.h" #include namespace llvm { @@ -94,7 +94,7 @@ public: void setPreservesAll() { PreservesAll = true; } bool getPreservesAll() const { return PreservesAll; } - /// setPreservesCFG - This function should be called by the pass, if they do + /// setPreservesCFG - This function should be called by the pass, iff they do /// not: /// /// 1. Add or remove basic blocks from the function @@ -129,7 +129,7 @@ public: // Find pass that is implementing PI. Pass *findImplPass(AnalysisID PI) { - Pass *ResultPass = 0; + Pass *ResultPass = nullptr; for (unsigned i = 0; i < AnalysisImpls.size() ; ++i) { if (AnalysisImpls[i].first == PI) { ResultPass = AnalysisImpls[i].second; @@ -182,7 +182,7 @@ AnalysisType *Pass::getAnalysisIfAvailable() const { const void *PI = &AnalysisType::ID; Pass *ResultPass = Resolver->getAnalysisIfAvailable(PI, true); - if (ResultPass == 0) return 0; + if (!ResultPass) return nullptr; // Because the AnalysisType may not be a subclass of pass (for // AnalysisGroups), we use getAdjustedAnalysisPointer here to potentially