Hello Group,
I am trying to come up with a list of compiler/linker options so that
when the following code is run, a run time failure is generated. Or at
least a compile time diagnosis is re****ted.
The target compiler is Intel ifort. I would like to catch as many
non-standard coding practice as possible at both compile time and run
time.
I currently use '-std -warn all -WB -Winline -traceback' but it does
not catch the error in the following code.
Thanks,
program test
integer, dimension(:), allocatable :: x
allocate(x(10))
call use_array(x)
contains
subroutine use_array(x)
integer, dimension(:), intent(in) :: x
integer, dimension(20) :: y
y = x
end subroutine use_array
end program


|