Commit 753721a5 by Paul Thomas

re PR fortran/79739 (ICE with some interesting code)

2017-02-28  Paul Thomas  <pault@gcc.gnu.org>

	PR fortran/79739
	* resolve.c (resolve_fl_procedure): Deal with the case where
	'submodule_name' is NULL so that gfc_error does not ICE.
	Reformat the error message to make it more consistent.

From-SVN: r245787
parent 2af0c3ed
2017-02-28 Paul Thomas <pault@gcc.gnu.org>
PR fortran/79739
* resolve.c (resolve_fl_procedure): Deal with the case where
'submodule_name' is NULL so that gfc_error does not ICE.
Reformat the error message to make it more consistent.
2017-02-28 Jakub Jelinek <jakub@redhat.com>
* parse.c (parse_critical_block): Use cond ? G_("...") : G_("...")
......
......@@ -12341,9 +12341,10 @@ resolve_fl_procedure (gfc_symbol *sym, int mp_flag)
if (!gfc_check_result_characteristics (sym, iface, errmsg, 200))
{
gfc_error ("%s between the MODULE PROCEDURE declaration "
"in module %s and the declaration at %L in "
"SUBMODULE %s", errmsg, module_name,
&sym->declared_at, submodule_name);
"in MODULE '%s' and the declaration at %L in "
"(SUB)MODULE '%s'",
errmsg, module_name, &sym->declared_at,
submodule_name ? submodule_name : module_name);
return false;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment