Commit 2d914461 by Jason Merrill Committed by Jason Merrill

decl.c (grokdeclarator): Catch parm with pointer to array of unknown bound here...

	* decl.c (grokdeclarator): Catch parm with pointer to array of
	unknown bound here...
	* method.c (process_overload_item): ...not here.

From-SVN: r21800
parent 09007174
1998-08-17 Jason Merrill <jason@yorick.cygnus.com>
* decl.c (grokdeclarator): Catch parm with pointer to array of
unknown bound here...
* method.c (process_overload_item): ...not here.
* gxxint.texi: Remove obsolete documentation of overloading code.
* decl.c (finish_enum): Also set TYPE_SIZE_UNIT.
......
......@@ -9607,6 +9607,11 @@ grokdeclarator (declarator, declspecs, decl_context, initialized, attrlist)
type = TREE_TYPE (type);
}
if (decl_context == PARM && TREE_CODE (type) == ARRAY_TYPE
&& TYPE_DOMAIN (type) == NULL_TREE)
cp_error ("parameter type includes pointer to array of unknown bound `%T'",
type);
/* Merge any constancy or volatility into the target type
for the pointer. */
......
......@@ -1241,7 +1241,7 @@ process_overload_item (parmtype, extra_Gcode)
OB_PUTC ('A');
if (TYPE_DOMAIN (parmtype) == NULL_TREE)
error("pointer/reference to array of unknown bound in parm type");
OB_PUTC ('_');
else
{
tree length = array_type_nelts (parmtype);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment