diff options
author | Craig Topper <craig.topper@gmail.com> | 2014-03-08 08:27:28 +0000 |
---|---|---|
committer | Craig Topper <craig.topper@gmail.com> | 2014-03-08 08:27:28 +0000 |
commit | c83e68f7326f424876198514eb2ad89110f52c45 (patch) | |
tree | bfc2d328801ff1f8ec2206613c4e3f8e429a500a /tools/opt/PrintSCC.cpp | |
parent | 838cb749dceb62a35d1966833f1a577cd61938ad (diff) | |
download | llvm-c83e68f7326f424876198514eb2ad89110f52c45.tar.gz llvm-c83e68f7326f424876198514eb2ad89110f52c45.tar.bz2 llvm-c83e68f7326f424876198514eb2ad89110f52c45.tar.xz |
[C++11] Add 'override' keyword to virtual methods that override their base class.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@203345 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'tools/opt/PrintSCC.cpp')
-rw-r--r-- | tools/opt/PrintSCC.cpp | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/tools/opt/PrintSCC.cpp b/tools/opt/PrintSCC.cpp index f2e77f0cef..cbc0a55996 100644 --- a/tools/opt/PrintSCC.cpp +++ b/tools/opt/PrintSCC.cpp @@ -37,11 +37,11 @@ namespace { 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 @@ namespace { 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>(); } |