[C++11] Add 'override' keyword to virtual methods that override their base class.
llvm-svn: 203345
diff --git a/llvm/tools/opt/PrintSCC.cpp b/llvm/tools/opt/PrintSCC.cpp
index f2e77f0..cbc0a55 100644
--- a/llvm/tools/opt/PrintSCC.cpp
+++ b/llvm/tools/opt/PrintSCC.cpp
@@ -37,11 +37,11 @@
struct CFGSCC : public FunctionPass {
static char ID; // Pass identification, replacement for typeid
CFGSCC() : FunctionPass(ID) {}
- bool runOnFunction(Function& func);
+ bool runOnFunction(Function& func) override;
- void print(raw_ostream &O, const Module* = 0) const { }
+ void print(raw_ostream &O, const Module* = 0) const override { }
- virtual void getAnalysisUsage(AnalysisUsage &AU) const {
+ void getAnalysisUsage(AnalysisUsage &AU) const override {
AU.setPreservesAll();
}
};
@@ -51,12 +51,12 @@
CallGraphSCC() : ModulePass(ID) {}
// run - Print out SCCs in the call graph for the specified module.
- bool runOnModule(Module &M);
+ bool runOnModule(Module &M) override;
- void print(raw_ostream &O, const Module* = 0) const { }
+ void print(raw_ostream &O, const Module* = 0) const override { }
// getAnalysisUsage - This pass requires the CallGraph.
- virtual void getAnalysisUsage(AnalysisUsage &AU) const {
+ void getAnalysisUsage(AnalysisUsage &AU) const override {
AU.setPreservesAll();
AU.addRequired<CallGraphWrapperPass>();
}