http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54107



--- Comment #14 from janus at gcc dot gnu.org 2013-01-26 11:31:24 UTC ---

(In reply to comment #13)

> (In reply to comment #12)

> > Here is an updated version of Mikael's patch, which is free of testsuite

> > regressions.

> 

> Indeed, it was not that difficult after all. :-)



Yeah, once you give it a try ... ;)



But seriously: Thanks for making a start on this (I guess it was a silly idea

from the start to try and copy everything).





> Are procedure dummy arguments mutually exclusive with non-NULL procedure

> interface, so that there is no dummy ambiguity in the array spec and char

> length?



I'm not sure I understand the question. You can certainly declare dummy

procedures with the PROCEDURE statement (so that they get a ts.interface).

Still, I don't see how this could create ambiguities with the as or cl. Or are

you talking about something like this:



procedure(some_interface) :: proc

integer(4) :: proc



Without checking the standard, I would guess that this is illegal. Not sure if

we reject it, though.





> > It fixes comment #0, but fails with a very strange backtrace on comment 4:

> 

> It seems to be an infinite recursion in gfc_get_function_type:

> 

> gfc_get_function_type (gfc_symbol * sym)

> {

>   [...]

>   for (f = gfc_sym_get_dummy_args (sym); f; f = f->next)

>     {

>       arg = f->sym;

>       if (arg)

>     {

>           [...]

>       if (arg->attr.flavor == FL_PROCEDURE)

>         {

>           type = gfc_get_function_type (arg);

>           type = build_pointer_type (type);

>         }



So, do you have an idea how to escape this infinite recursion?

Reply via email to