aboutsummaryrefslogtreecommitdiff
path: root/llvm/unittests/Support/AlignOfTest.cpp
diff options
context:
space:
mode:
authorAlexander Kornienko <alexfh@google.com>2015-04-11 02:11:45 +0000
committerAlexander Kornienko <alexfh@google.com>2015-04-11 02:11:45 +0000
commitf817c1cb9afe641516b21fcc6e400681025f18f9 (patch)
tree06bc60f7ff86fcc42f6b97ac69337b5b691528ae /llvm/unittests/Support/AlignOfTest.cpp
parent34eb20725d9d923f6f2ff9f205f198d5f3df022b (diff)
downloadllvm-f817c1cb9afe641516b21fcc6e400681025f18f9.zip
llvm-f817c1cb9afe641516b21fcc6e400681025f18f9.tar.gz
llvm-f817c1cb9afe641516b21fcc6e400681025f18f9.tar.bz2
Use 'override/final' instead of 'virtual' for overridden methods
The patch is generated using clang-tidy misc-use-override check. This command was used: tools/clang/tools/extra/clang-tidy/tool/run-clang-tidy.py \ -checks='-*,misc-use-override' -header-filter='llvm|clang' \ -j=32 -fix -format http://reviews.llvm.org/D8925 llvm-svn: 234679
Diffstat (limited to 'llvm/unittests/Support/AlignOfTest.cpp')
-rw-r--r--llvm/unittests/Support/AlignOfTest.cpp20
1 files changed, 15 insertions, 5 deletions
diff --git a/llvm/unittests/Support/AlignOfTest.cpp b/llvm/unittests/Support/AlignOfTest.cpp
index b9d423e..e0859fc 100644
--- a/llvm/unittests/Support/AlignOfTest.cpp
+++ b/llvm/unittests/Support/AlignOfTest.cpp
@@ -61,12 +61,22 @@ struct D8 : S1, D4, D5 { double x[2]; };
struct D9 : S1, D1 { S1 s1; };
struct V1 { virtual ~V1(); };
struct V2 { int x; virtual ~V2(); };
-struct V3 : V1 { virtual ~V3(); };
-struct V4 : virtual V2 { int y; virtual ~V4(); };
-struct V5 : V4, V3 { double z; virtual ~V5(); };
+struct V3 : V1 {
+ ~V3() override;
+};
+struct V4 : virtual V2 { int y;
+ ~V4() override;
+};
+struct V5 : V4, V3 { double z;
+ ~V5() override;
+};
struct V6 : S1 { virtual ~V6(); };
-struct V7 : virtual V2, virtual V6 { virtual ~V7(); };
-struct V8 : V5, virtual V6, V7 { double zz; virtual ~V8(); };
+struct V7 : virtual V2, virtual V6 {
+ ~V7() override;
+};
+struct V8 : V5, virtual V6, V7 { double zz;
+ ~V8() override;
+};
double S6::f() { return 0.0; }
float D2::g() { return 0.0f; }