summaryrefslogtreecommitdiffstats
path: root/test/SemaTemplate/dependent-names.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'test/SemaTemplate/dependent-names.cpp')
-rw-r--r--test/SemaTemplate/dependent-names.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/test/SemaTemplate/dependent-names.cpp b/test/SemaTemplate/dependent-names.cpp
index a2d3c56..7796106 100644
--- a/test/SemaTemplate/dependent-names.cpp
+++ b/test/SemaTemplate/dependent-names.cpp
@@ -18,15 +18,18 @@ template<class T> class R : Q<T> {T current;};
namespace test0 {
template <class T> class Base {
+ public:
void instance_foo();
static void static_foo();
class Inner {
+ public:
void instance_foo();
static void static_foo();
};
};
template <class T> class Derived1 : Base<T> {
+ public:
void test0() {
Base<T>::static_foo();
Base<T>::instance_foo();
@@ -49,6 +52,7 @@ namespace test0 {
};
template <class T> class Derived2 : Base<T>::Inner {
+ public:
void test0() {
Base<T>::static_foo();
Base<T>::instance_foo(); // expected-error {{call to non-static member function without an object argument}}
OpenPOWER on IntegriCloud