------- Comment #5 from burnus at gcc dot gnu dot org 2008-04-11 07:45 ------- > If on the other hand Tobias is right in the assumption he made in comment #3, > then one could something along the lines of > if (f1->sym->as->type != f2->sym->as->type)
I would not be surprised if foo(*) and foo(4) are allowed and then your test rejects too much. > My feeling is that at least the array size should match for explicit-shape > arrays, I'm not sure about that part; one can create "valid" (i.e. working) programs which violate this (e.g.: array(5), array(10), but only accessing 1 to 5). We should check what the standard says about this. I think it is formally invalid to do so; if we decide to allow it, at least a warning should be printed. (At the end one needs to carefully read the standard, unfortunately, I do not have much time the next two, three weeks. One could also ask at comp.lang.fortran.) -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35831