+2016-08-31 David Malcolm <dmalcolm@redhat.com>
+
+ * c-parser.c (c_parser_declaration_or_fndef): Add trailing space
+ to the insertion fixits for "struct", "union", and "enum".
+
2016-08-30 David Malcolm <dmalcolm@redhat.com>
* c-decl.c (implicit_decl_warning): Use add_fixit_replace
if (tag_exists_p (RECORD_TYPE, name))
{
/* This is not C++ with its implicit typedef. */
- richloc.add_fixit_insert ("struct");
+ richloc.add_fixit_insert ("struct ");
error_at_rich_loc (&richloc,
"unknown type name %qE;"
" use %<struct%> keyword to refer to the type",
}
else if (tag_exists_p (UNION_TYPE, name))
{
- richloc.add_fixit_insert ("union");
+ richloc.add_fixit_insert ("union ");
error_at_rich_loc (&richloc,
"unknown type name %qE;"
" use %<union%> keyword to refer to the type",
}
else if (tag_exists_p (ENUMERAL_TYPE, name))
{
- richloc.add_fixit_insert ("enum");
+ richloc.add_fixit_insert ("enum ");
error_at_rich_loc (&richloc,
"unknown type name %qE;"
" use %<enum%> keyword to refer to the type",