------- Comment #2 from burnus at gcc dot gnu dot org  2007-03-16 15:56 -------
(In reply to comment #1)
> All compilers I know reject this code, except g95. The list includes Lahey,
> which is a reason for me to doubt whether this code is legal or not.

NAG f95 and g95 compile it and output:
 21
 ABCDEFGHIJKLMNOPQRSTUABCDEFGHIJKLMNOPQRSTUABCDEFGHIJKLMNOPQRSTU

(ifort, sunf95 write:
         dimension r(modulo(len(r)-1,3)+1)
--------------------------------^
fortcom: Error: foo.f90, line 6: The data types of the argument(s) are invalid.
  [LEN]
         dimension r(modulo(len(r)-1,3)+1)
                                ^
"foo.f90", Line = 6, Column = 33: ERROR: Array "R" is used recursively to
declare its own bounds.
--------------------------------

In any case, an ICE is an error.


-- 

burnus at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |burnus at gcc dot gnu dot
                   |                            |org


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

Reply via email to