OK.
Jason
Hi,
On 10/25/2012 03:53 AM, Jason Merrill wrote:
We can stop it even sooner:
/* If the next token is an ellipsis, and we don't already have it
marked as a parameter pack, then we have a parameter pack (that
has no declarator). */
if (!*is_parameter_pack
&& cp_lexer_next_to
We can stop it even sooner:
/* If the next token is an ellipsis, and we don't already have it
marked as a parameter pack, then we have a parameter pack (that
has no declarator). */
if (!*is_parameter_pack
&& cp_lexer_next_token_is (parser->lexer, CPP_ELLIPSIS)
&& decla
Hi again,
On 10/24/2012 09:53 PM, Jason Merrill wrote:
The parm shouldn't be a parameter pack in that case; the ... is part
of the default argument, not the parameter.
I tracked down where this goes wrong, in the parser: the below
recognizes when cp_parser_parameter_declaration doesn't parse a
On 10/24/2012 09:53 PM, Jason Merrill wrote:
On 10/24/2012 02:11 PM, Paolo Carlini wrote:
The problem is that the first time we go through the loop, when parm_idx
== 0 and TREE_PURPOSE is error_mark_node, the condition:
if (template_parameter_pack_p (TREE_VALUE (parm))
&& !(arg &&
On 10/24/2012 02:11 PM, Paolo Carlini wrote:
The problem is that the first time we go through the loop, when parm_idx
== 0 and TREE_PURPOSE is error_mark_node, the condition:
if (template_parameter_pack_p (TREE_VALUE (parm))
&& !(arg && ARGUMENT_PACK_P (arg)))
near the beginning o
Hi,
On 10/24/2012 07:30 PM, Jason Merrill wrote:
On 10/24/2012 01:20 PM, Paolo Carlini wrote:
+ if (parm == error_mark_node
+ || TREE_PURPOSE (parm) == error_mark_node)
It seems odd to bail out early if the default argument is bad even if
we aren't trying to use it. Doesn't it wor
On 10/24/2012 01:20 PM, Paolo Carlini wrote:
+ if (parm == error_mark_node
+ || TREE_PURPOSE (parm) == error_mark_node)
It seems odd to bail out early if the default argument is bad even if we
aren't trying to use it. Doesn't it work to check this further down
where we actually
Hi,
a *very* old ICE on invalid, even a regression (from before variadic
templates, I guess!). I tried various other tweaks, like catching the
issue earlier but diagnostic quality decreases, too many cascading error
messages. The below means I have to tweak only a couple of existing
testcases