Stefano Lattarini stefano.lattarini@gmail.com
Steve Murphy murf@parsetree.com
Sum Wu sum@geekhouse.org
+Théophile Ranquet theophile.ranquet@gmail.com
Thiru Ramakrishnan thiru.ramakrishnan@gmail.com
Tim Josling tej@melbpc.org.au
Tim Landscheidt tim@tim-landscheidt.de
Local Variables:
mode: text
+coding: utf-8
End:
-----
extern "C" {
# endif
+/* Sub-messages indent. */
+#define SUB_INDENT (4)
+
/** Record that a warning is about to be issued, and treat it as an
error if <tt>warnings_flag & warnings_error</tt>. This is exported
only for the sake of Yacc-compatible conflict reports in conflicts.c.
aver (merge_function != NULL && merger_find == merger);
if (merge_function->type != NULL && !UNIQSTR_EQ (merge_function->type, type))
{
- complain_at (declaration_loc,
- _("result type clash on merge function %s: <%s> != <%s>"),
- quote (merge_function->name), type, merge_function->type);
- complain_at (merge_function->type_declaration_location,
- _("previous declaration"));
- }
+ unsigned indent = 0;
+ complain_at_indent (declaration_loc, &indent,
+ _("result type clash on merge function %s: "
+ "<%s> != <%s>"),
+ quote (merge_function->name), type,
+ merge_function->type);
+ indent += SUB_INDENT;
+ complain_at_indent (merge_function->type_declaration_location, &indent,
+ _("previous declaration"));
+ }
merge_function->type = uniqstr_new (type);
merge_function->type_declaration_location = declaration_loc;
}
AT_BISON_CHECK([[-o glr-regr18.c glr-regr18.y]], 1, [],
[glr-regr18.y:26.18-24: result type clash on merge function 'merge': <type2> != <type1>
-glr-regr18.y:25.18-24: previous declaration
+glr-regr18.y:25.18-24: previous declaration
glr-regr18.y:27.13-19: result type clash on merge function 'merge': <type3> != <type2>
-glr-regr18.y:26.18-24: previous declaration
+glr-regr18.y:26.18-24: previous declaration
])
AT_CLEANUP