decl.c (grokdeclarator): Assert that we won't see a pointer to METHOD_TYPE.
* decl.c (grokdeclarator): Assert that we won't see a pointer to METHOD_TYPE. From-SVN: r196748
This commit is contained in:
parent
bab5167fe6
commit
d1f45df55b
|
@ -1,5 +1,8 @@
|
||||||
2013-03-16 Jason Merrill <jason@redhat.com>
|
2013-03-16 Jason Merrill <jason@redhat.com>
|
||||||
|
|
||||||
|
* decl.c (grokdeclarator): Assert that we won't see a pointer to
|
||||||
|
METHOD_TYPE.
|
||||||
|
|
||||||
PR c++/54277
|
PR c++/54277
|
||||||
* cp-tree.h (WILDCARD_TYPE_P): Split out from...
|
* cp-tree.h (WILDCARD_TYPE_P): Split out from...
|
||||||
(MAYBE_CLASS_TYPE_P): ...here.
|
(MAYBE_CLASS_TYPE_P): ...here.
|
||||||
|
|
|
@ -9630,9 +9630,11 @@ grokdeclarator (const cp_declarator *declarator,
|
||||||
but to the target of the pointer. */
|
but to the target of the pointer. */
|
||||||
type_quals = TYPE_UNQUALIFIED;
|
type_quals = TYPE_UNQUALIFIED;
|
||||||
|
|
||||||
|
/* This code used to handle METHOD_TYPE, but I don't think it's
|
||||||
|
possible to get it here anymore. */
|
||||||
|
gcc_assert (TREE_CODE (type) != METHOD_TYPE);
|
||||||
if (declarator->kind == cdk_ptrmem
|
if (declarator->kind == cdk_ptrmem
|
||||||
&& (TREE_CODE (type) == FUNCTION_TYPE
|
&& TREE_CODE (type) == FUNCTION_TYPE)
|
||||||
|| (memfn_quals && TREE_CODE (type) == METHOD_TYPE)))
|
|
||||||
{
|
{
|
||||||
memfn_quals |= type_memfn_quals (type);
|
memfn_quals |= type_memfn_quals (type);
|
||||||
type = build_memfn_type (type,
|
type = build_memfn_type (type,
|
||||||
|
|
Loading…
Reference in New Issue