>> in principle I think your idea to tighten up the type check by
>> symmetrizing it is ok.
>
> I actually kind of copied it from the proc-pointer assignment check, which
> does the same.
Btw, I think you refer to this piece of code in expr.c
(gfc_check_pointer_assign), right?
if (!gfc_compare_interfaces (s1, s2, name, 0, 1,
err, sizeof(err), NULL, NULL))
{
gfc_error ("Interface mismatch in procedure pointer assignment "
"at %L: %s", &rvalue->where, err);
return false;
}
if (!gfc_compare_interfaces (s2, s1, name, 0, 1,
err, sizeof(err), NULL, NULL))
{
gfc_error ("Interface mismatch in procedure pointer assignment "
"at %L: %s", &rvalue->where, err);
return false;
}
Since this will ultimately rely on check_dummy_characteristics, too,
it might even be possible to remove the duplication here, after my
patch introduces the symmetrization on a deeper level ... ?
Cheers,
Janus