http://gcc.gnu.org/bugzilla/show_bug.cgi?id=45170
--- Comment #41 from I M 2013-02-05
16:36:41 UTC ---
With version 4.7.2 this bug still exists. Is there any timeline to fix it?
The following code
module thing
implicit none
character(len=:), allocatable :: array_of_chars(:)
contains
subroutine allocatestuff()
implicit none
integer :: length_names = 15
integer :: number_arrays = 5
allocate(character(15) :: array_of_chars(number_arrays))
!allocate(character(length_names) :: array_of_chars(number_arrays))
end subroutine allocatestuff
end module thing
program test1
implicit none
call allocatestuff()
end program test1
Both allocates triggers the bug. If the same code is in the main program and
not in a module the first allocate works, but the second doesn't.