This is the mail archive of the gcc-help@gcc.gnu.org mailing list for the GCC project.
| Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
|---|---|---|
| Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |
| Other format: | [Raw text] | |
Germund,
The following works with gfortran
[prt@localhost svn]# cat demo.f90 program test_arg character(80) :: buffer narg = iargc () print *, "no. of args = ", narg do i = 1, narg call getarg (i, buffer) print *, buffer end do end program test_arg
[prt@localhost svn]# ./a.out my arg your arg no. of args = 4 my arg your arg
Whilst not standard (as using -std=f95 will demonstrate), this is a fairly common manifestation of argument reading in fortran.
Regards
Paul Thomas
-- Dr. Germund Hojer Depto. Fisica y Quimica Teorica Facultad de Quimica UNAM germund.hojer@servidor.unam.mx
| Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
|---|---|---|
| Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |