+2017-05-18 Fritz Reese <fritzoreese@gmail.com>
+
+ PR fortran/79968
+ * decl.c (match_attr_spec, gfc_match_automatic,
+ gfc_match_static, gfc_match_structure_decl): Unify diagnostic
+ errors regarding -fdec options.
+ * io.c (match_dec_etag, match_dec_vtag, match_dec_ftag): Ditto.
+
2017-05-17 Jerry DeLisle <jvdelisle@gcc.gnu.org>
PR fortran/80741
if ((d == DECL_STATIC || d == DECL_AUTOMATIC)
&& !flag_dec_static)
{
- gfc_error ("%s at %L is a DEC extension, enable with -fdec-static",
+ gfc_error ("%s at %L is a DEC extension, enable with "
+ "%<-fdec-static%>",
d == DECL_STATIC ? "STATIC" : "AUTOMATIC", &seen_at[d]);
m = MATCH_ERROR;
goto cleanup;
if (!flag_dec_static)
{
- gfc_error ("AUTOMATIC at %C is a DEC extension, enable with "
- "-fdec-static");
+ gfc_error ("%s at %C is a DEC extension, enable with "
+ "%<-fdec-static%>",
+ "AUTOMATIC"
+ );
return MATCH_ERROR;
}
if (!flag_dec_static)
{
- gfc_error ("STATIC at %C is a DEC extension, enable with -fdec-static");
+ gfc_error ("%s at %C is a DEC extension, enable with "
+ "%<-fdec-static%>",
+ "STATIC");
return MATCH_ERROR;
}
if (!flag_dec_structure)
{
- gfc_error ("STRUCTURE at %C is a DEC extension, enable with "
- "-fdec-structure");
+ gfc_error ("%s at %C is a DEC extension, enable with "
+ "%<-fdec-structure%>",
+ "STRUCTURE");
return MATCH_ERROR;
}
return m;
else if (m != MATCH_NO)
{
- gfc_error ("%s is a DEC extension at %C, re-compile with "
- "-fdec to enable", tag->name);
+ gfc_error ("%s at %C is a DEC extension, enable with "
+ "%<-fdec%>", tag->name);
return MATCH_ERROR;
}
return m;
return m;
else if (m != MATCH_NO)
{
- gfc_error ("%s is a DEC extension at %C, re-compile with "
- "-fdec to enable", tag->name);
+ gfc_error ("%s at %C is a DEC extension, enable with "
+ "%<-fdec%>", tag->name);
return MATCH_ERROR;
}
return m;
if (!flag_dec)
{
- gfc_error ("%s is a DEC extension at %C, re-compile with "
- "-fdec to enable", tag->name);
+ gfc_error ("%s at %C is a DEC extension, enable with "
+ "%<-fdec%>", tag->name);
return MATCH_ERROR;
}