------- Comment #6 from fxcoudert at gcc dot gnu dot org 2007-10-02 11:27 ------- (In reply to comment #5) > Really? From how I read the standard (F2K draft), UBOUND(ARRAY, DIM) has (in > this case) "a value equal to the upper bound for subscript DIM of ARRAY". I > can't see it allowing returning random values such as 2193121.
The program shown is not valid Fortran, the processor can do whatever it wants. A most sensible choice would be to reject it, of course: that's what g95 does (and g77 also, according to Paul) but others have chosen to segfault (Intel, Sun). -- fxcoudert at gcc dot gnu dot org changed: What |Removed |Added ---------------------------------------------------------------------------- GCC build triplet|x86_64-linux-gnu | GCC host triplet|x86_64-linux-gnu | GCC target triplet|x86_64-linux-gnu | http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31346