re PR c++/27078 (Duplicate error message for ambiguous enum)
PR c++/27078 * parser.c (cp_parser_primary_expression): Don't give a duplicate ambiguity error. From-SVN: r154139
This commit is contained in:
parent
2c312924d5
commit
3791ce90f6
|
@ -1,5 +1,9 @@
|
|||
2009-11-12 Jason Merrill <jason@redhat.com>
|
||||
|
||||
PR c++/27078
|
||||
* parser.c (cp_parser_primary_expression): Don't give a duplicate
|
||||
ambiguity error.
|
||||
|
||||
PR c++/39560
|
||||
* decl2.c (build_anon_union_vars): Set DECL_ARTIFICIAL.
|
||||
|
||||
|
@ -10,16 +14,12 @@
|
|||
* call.c (build_conditional_expr): Check specifically for folding
|
||||
to CALL_EXPR rather than TREE_SIDE_EFFECTS.
|
||||
|
||||
2009-11-12 Jason Merrill <jason@redhat.com>
|
||||
|
||||
* typeck.c (cv_qualified_p): New fn.
|
||||
(decay_conversion): Use it.
|
||||
* cp-tree.h: Declare it.
|
||||
* tree.c (rvalue): Use it and cv_unqualified.
|
||||
* init.c (build_aggr_init): Likewise.
|
||||
|
||||
2009-11-12 Jason Merrill <jason@redhat.com>
|
||||
|
||||
PR c++/42013
|
||||
* call.c (build_conditional_expr): Don't fold a TREE_SIDE_EFFECTS
|
||||
COND_EXPR in unevaluated context.
|
||||
|
@ -33,8 +33,6 @@
|
|||
PR c++/39131
|
||||
* rtti.c (emit_support_tinfos): Add DFP types.
|
||||
|
||||
2009-11-11 Jason Merrill <jason@redhat.com>
|
||||
|
||||
* call.c (build_op_delete_call): Downgrade error about
|
||||
placement/non-placement confusion to permerror.
|
||||
|
||||
|
|
|
@ -3509,6 +3509,16 @@ cp_parser_primary_expression (cp_parser *parser,
|
|||
{
|
||||
tree ambiguous_decls;
|
||||
|
||||
/* If we already know that this lookup is ambiguous, then
|
||||
we've already issued an error message; there's no reason
|
||||
to check again. */
|
||||
if (id_expr_token->type == CPP_NAME
|
||||
&& id_expr_token->ambiguous_p)
|
||||
{
|
||||
cp_parser_simulate_error (parser);
|
||||
return error_mark_node;
|
||||
}
|
||||
|
||||
decl = cp_parser_lookup_name (parser, id_expression,
|
||||
none_type,
|
||||
template_p,
|
||||
|
|
Loading…
Reference in New Issue