diff options
author | Dimitry Andric <dim@FreeBSD.org> | 2015-01-18 16:23:48 +0000 |
---|---|---|
committer | Dimitry Andric <dim@FreeBSD.org> | 2015-01-18 16:23:48 +0000 |
commit | 06d4ba388873e6d1cfa9cd715a8935ecc8cd2097 (patch) | |
tree | 3eb853da77d46cc77c4b017525a422f9ddb1385b /test/SemaCXX/using-decl-1.cpp | |
parent | 30d791273d07fac9c0c1641a0731191bca6e8606 (diff) |
Notes
Diffstat (limited to 'test/SemaCXX/using-decl-1.cpp')
-rw-r--r-- | test/SemaCXX/using-decl-1.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/test/SemaCXX/using-decl-1.cpp b/test/SemaCXX/using-decl-1.cpp index 40f80a70ef37..e730c9d63a20 100644 --- a/test/SemaCXX/using-decl-1.cpp +++ b/test/SemaCXX/using-decl-1.cpp @@ -255,3 +255,11 @@ namespace TypoCorrectTemplateMember { using A::goobar; // expected-error {{no member named 'goobar' in 'TypoCorrectTemplateMember::A'; did you mean 'foobar'?}} }; } + +namespace use_instance_in_static { +struct A { int n; }; +struct B : A { + using A::n; + static int f() { return n; } // expected-error {{invalid use of member 'n' in static member function}} +}; +} |