Drew McCormack wrote:
> Does that mean that this call would be legal?
>
> real :: arg(5)
> call sub( arg(2) )
>
> If that is legal and 'call sub(a)' is not, then I think Fortran 90 is
> a pretty subtle language.
No, arg(2) is a scalar, so it cannot be passed to sub.
call sub(arg(2:))
might be legal though, depending on the declared size of the dummy of
sub (which is 10 in your case so it would not be legal either).
This is not as subtle as it seems once explained. But yes, the reasons
behind the choices are subtle, and often historical...
Aleks
|