Patchwork PR c++/16630 missing type name in __PRETTY_FUNCTION__

login
register
mail settings
Submitter Manuel López-Ibáñez
Date July 4, 2010, 6:19 p.m.
Message ID <AANLkTinYB4MTUUA6hkkofNDbnFjvYRG4AaOwSYSuzFlN@mail.gmail.com>
Download mbox | patch
Permalink /patch/57849/
State New
Headers show

Comments

Manuel López-Ibáñez - July 4, 2010, 6:19 p.m.
I committed as obvious the testcase of PR 16630 so we do not regress
in the future.

Cheers,

Manuel


B<U>::X\\)" } }

Patch

Index: gcc/testsuite/ChangeLog
===================================================================
--- gcc/testsuite/ChangeLog     (revision 161804)
+++ gcc/testsuite/ChangeLog     (revision 161805)
@@ -1,3 +1,8 @@ 
+2010-07-04  Manuel López-Ibáñez  <manu@gcc.gnu.org>
+
+       PR c++/16630
+       * g++.dg/ext/pretty3.C: New.
+
 2010-07-04  Richard Guenther  <rguenther@suse.de>

        PR middle-end/44809
Index: gcc/testsuite/g++.dg/ext/pretty3.C
===================================================================
--- gcc/testsuite/g++.dg/ext/pretty3.C  (revision 0)
+++ gcc/testsuite/g++.dg/ext/pretty3.C  (revision 161805)
@@ -0,0 +1,19 @@ 
+// PR c++/16630
+// { dg-do compile }
+// { dg-options "" }
+extern "C" int printf (const char*, ...);
+
+template <class T>
+struct B { typedef T X; };
+
+template <class U>
+struct D
+{
+  const char* foo (typename B<U>::X) { return __PRETTY_FUNCTION__; }
+};
+
+int main ()
+{
+  printf ("%s\n", D<int>().foo (0));
+}
+// { dg-final { scan-assembler "const char\\* D<U>::foo\\(typename