equivalence croakage

Dominique Dhumieres dominiq@lps.ens.fr
Mon Nov 2 16:39:00 GMT 2009


If I replace 'data j(2)/7/' with 'data j/1,1/' I get

equiv_bad_1.f90:3.11:

data i(1)/5/
           1
Error: Overlapping unequal initializers in EQUIVALENCE at (1)

which may lead the user to what's wrong (a double locus would be
more helpful). For the code in http://gcc.gnu.org/ml/fortran/2009-11/msg00011.html
the error is very unfriendly:

<During initialization>

Error: Overlapping unequal initializers in EQUIVALENCE at (1)

"<During initialization>" is generated when there is no known locus.
I find also "unequal" misleading: once you know what the problem is,
it is "unequal values for the same memory location(s)", but if
you don't know what's going wrong, you can think that it is the length
of the data, ... .

Dominique



More information about the Fortran mailing list