Thanx,
Yiorgox
Just because assuming that size is known is wrong. A(*) means that actual
size in the calling routine doesn't matter to the system, because
the programmer is supposed to be able to know it by some other means.
--
Michel OLAGNON email : Michel....@ifremer.fr
http://www.ifremer.fr/metocean/group/michel/michel_olagnon.htm
http://www.fortran-2000.com/
Because the debugger has no information of the length of the array you are
watching. A(*) ia an assumed size array. Try to modify your routine like
this:
old:
subroutine foo(arr)
implicit none
integer,dimension(*) :: arr
<more code>
end
new:
subroutine foo(dim,arr)
implicit none
integer :: dim
integer,dimension(dim) :: arr
<more code>
end
The new routine passes the length of arr to the subroutine. The debugger now
can display all elements.
Greetings,
Michael
--
Dipl.-Ing. Michael Sabielny
Technical University of Hamburg-Harburg
Department of Theoretical Electrical Engineering
D-21071 Hamburg
Germany
Apart from the fact that I will be able to see all the elements in the watch
window, would this kind of approach be more efficient programming than what
I have been doing (dim A(*))???
Yiorgos
DIMENSION A(*) does not mean that the program knows the size of the
array. It just means that A is an array, and that the programmer will
have to pay attention to respect the size. The debugger has no
information of the size of A.
For debugging, you can try typing A(1:100), or A(1:something),
depending on how many elements you want to see. I know this works in
CVF, I don't know for other debuggers.
Hope this helps
Pat