Index: tools/clang/plugins/tests/virtual_specifiers.cpp |
diff --git a/tools/clang/plugins/tests/virtual_specifiers.cpp b/tools/clang/plugins/tests/virtual_specifiers.cpp |
index 4d9acd38ac035c2820c5a28f9dc6ca5fc0d7cf73..28321e8bdf5c29aed7fd2343b398eb8cad360b6c 100644 |
--- a/tools/clang/plugins/tests/virtual_specifiers.cpp |
+++ b/tools/clang/plugins/tests/virtual_specifiers.cpp |
@@ -62,6 +62,23 @@ class OverrideAndFinal : public Base { |
void F() OVERRIDE FINAL {} |
}; |
+// Also warn on pure functions. |
+class CorrectPureVirtual : public Base { |
+ virtual void F() = 0; |
+}; |
+ |
+class Pure : public Base { |
+ void F() = 0; |
+}; |
+ |
+class PureOverride : public Base { |
+ void F() override = 0; |
+}; |
+ |
+class PureVirtualOverride : public Base { |
+ virtual void F() override = 0; |
+}; |
+ |
// Finally, some simple sanity tests that overrides in the testing namespace |
// don't trigger warnings, except for testing::Test. |
namespace testing { |