@@ -7263,6 +7263,7 @@ potential_constant_expression_1 (tree t, bool want_rval, tsubst_flags_t flags)
{
case FUNCTION_DECL:
case BASELINK:
+ case TEMPLATE_DECL:
case OVERLOAD:
case TEMPLATE_ID_EXPR:
case LABEL_DECL:
deleted file mode 100644
@@ -1,10 +0,0 @@
-// PR c++/46903
-// This isn't C++0x code, but it was breaking in C++0x mode.
-// { dg-options -std=c++0x }
-
-struct A {};
-struct B {
- void *(*a)();
-};
-template <typename T> void *CreateA() {}
-B b = {CreateA<A>};
deleted file mode 100644
@@ -1,13 +0,0 @@
-// PR c++/46552
-// { dg-options -std=c++0x }
-
-struct S
-{
- int x;
-};
-
-template < typename >
-void f( void )
-{
- &S::x;
-}
new file mode 100644
@@ -0,0 +1,3 @@
+This directory contains tests that were passing in C++98 mode but failing
+in C++0x mode; it should be replaced by an improvement to the test harness
+to run all tests in both modes.
new file mode 100644
@@ -0,0 +1,10 @@
+// PR c++/46903
+// This isn't C++0x code, but it was breaking in C++0x mode.
+// { dg-options -std=c++0x }
+
+struct A {};
+struct B {
+ void *(*a)();
+};
+template <typename T> void *CreateA() {}
+B b = {CreateA<A>};
new file mode 100644
@@ -0,0 +1,13 @@
+// PR c++/46552
+// { dg-options -std=c++0x }
+
+struct S
+{
+ int x;
+};
+
+template < typename >
+void f( void )
+{
+ &S::x;
+}
new file mode 100644
@@ -0,0 +1,13 @@
+// PR c++/47511
+// { dg-options -std=c++0x }
+
+namespace N {
+ template <typename T> bool g( T ) {
+ return true;
+ }
+ struct A { };
+}
+template <class T> void f(const T&) {
+ N::A x;
+ g(x) ;
+}