]> gcc.gnu.org Git - gcc.git/commitdiff
decl.c (grokdeclarator): Reject pointer to qualified function type.
authorJason Merrill <jason@redhat.com>
Tue, 31 Mar 2009 19:06:17 +0000 (15:06 -0400)
committerJason Merrill <jason@gcc.gnu.org>
Tue, 31 Mar 2009 19:06:17 +0000 (15:06 -0400)
        * decl.c (grokdeclarator): Reject pointer to qualified function
        type.

From-SVN: r145367

gcc/cp/ChangeLog
gcc/testsuite/ChangeLog
gcc/testsuite/g++.dg/other/typedef2.C [new file with mode: 0644]

index 95079f15c31fb75291a10f7b1fd01b25bfff427d..9782f94d923959af6a27533f4c68a5e23ab3d70c 100644 (file)
@@ -1,6 +1,9 @@
 2009-03-31  Jason Merrill  <jason@redhat.com>
 
-       PR c++/37806
+       * decl.c (grokdeclarator): Reject pointer to qualified function
+       type.
+
+       PR c++/37806, core issue 547
        * typeck.c (cp_apply_type_quals_to_decl): Don't apply any quals
        to a typedef.
        * tree.c (cp_build_qualified_type_real): Don't apply restrict to a 
index 5205c3903f0cfd1958089897e95bf72efbc6aadb..7d71e74701effb901f86129de7daa9222bded33a 100644 (file)
@@ -1,5 +1,7 @@
 2009-03-31  Jason Merrill  <jason@redhat.com>
 
+       * g++.dg/other/typedef2.C: New test.
+
        PR c++/37806
        * g++.dg/template/typedef17.C: New test.
 
diff --git a/gcc/testsuite/g++.dg/other/typedef2.C b/gcc/testsuite/g++.dg/other/typedef2.C
new file mode 100644 (file)
index 0000000..902e102
--- /dev/null
@@ -0,0 +1,3 @@
+typedef void fn() const;
+
+fn* fp;                         // { dg-error "pointer.*qualified function type" }
This page took 0.083227 seconds and 5 git commands to generate.