I ran the gfortran testsuite with -fbounds-check and found a few failures (on i686-linux), among which was gfortran.dg/aliasing_dummy_1.f90. Here is a reduced testcase: program test_lex type :: dtype character*5 :: word end type dtype type :: list type(dtype) :: list(1) end type list type(list) :: table call foo1 (table%list(1)%word) contains subroutine foo1 (slist) character(*), dimension(*) :: slist write (slist(1), '(i5)') 0 end subroutine foo1 end program test_lex $ gfortran -fbounds-check bug.f90 && ./a.out Fortran runtime error: Array reference out of bounds
I bet $ 100 (or a beer at the GCC summit if you come) that the problem is with dimension(*) Which means this is a dup of bug 19777.
Right you are. Closed as duplicate. *** This bug has been marked as a duplicate of 19777 ***
(In reply to comment #2) > Right you are. Closed as duplicate. FX, Are you comming to the GCC summit?
(In reply to comment #3) > FX, Are you comming to the GCC summit? Well, my employer has nothing to do with gfortra, so I won't be coming. But if you ever come to Paris, I'll offer you a beer!