summaryrefslogtreecommitdiff
path: root/compilerplugins
diff options
context:
space:
mode:
authorMiklos Vajna <vmiklos@collabora.co.uk>2016-11-24 09:02:38 +0100
committerMiklos Vajna <vmiklos@collabora.co.uk>2016-11-24 12:11:59 +0100
commit7aa2b5a041df8e71a435cccbc79ee13799ec9138 (patch)
tree72dfbe1661b4876a0fa5efb97d5379a7c30fd367 /compilerplugins
parent8a34ff14f18da0df261ae8f1ca3f23de157706a1 (diff)
CompilerTest_compilerplugins_clang: fix this to work with clang-3.7
Change-Id: I653b9c3aba53da421592b230bee3a9b69d3cb2d7
Diffstat (limited to 'compilerplugins')
-rw-r--r--compilerplugins/clang/test/datamembershadow.cxx5
1 files changed, 5 insertions, 0 deletions
diff --git a/compilerplugins/clang/test/datamembershadow.cxx b/compilerplugins/clang/test/datamembershadow.cxx
index 663750a0c22d..24a0da9f99de 100644
--- a/compilerplugins/clang/test/datamembershadow.cxx
+++ b/compilerplugins/clang/test/datamembershadow.cxx
@@ -8,6 +8,8 @@
*/
+// '#if CLANG_VERSION >= 30800' covers large parts of compilerplugins/clang/datamembershadow.cxx
+#if (__clang_major__ == 3 && __clang_minor__ >= 8) || __clang_major__ > 3
struct Bar {
int x; // expected-note {{superclass member here [loplugin:datamembershadow]}}
};
@@ -15,5 +17,8 @@ struct Bar {
struct Foo : public Bar {
int x; // expected-error {{data member x is shadowing member in superclass, through inheritance path Foo->Bar [loplugin:datamembershadow]}}
};
+#else
+// expected-no-diagnostics
+#endif
/* vim:set shiftwidth=4 softtabstop=4 expandtab cinoptions=b1,g0,N-s cinkeys+=0=break: */