Dead
[official-gcc.git] / gomp-20050608-branch / gcc / testsuite / gfortran.fortran-torture / execute / getarg_1.f90
blob2d566862d2d7aff70e4b3ce58e71921ac85de8a3
1 ! Check that getarg does somethig sensible.
2 program getarg_1
3 CHARACTER*10 ARGS
4 INTEGER*4 I
5 I = 0
6 CALL GETARG(I,ARGS)
7 ! This should return the invoking command. The actual value depends
8 ! on the OS, but a blank string is wrong no matter what.
9 ! ??? What about deep embedded systems?
10 if (args.eq.'') call abort
11 I = 1
12 CALL GETARG(I,ARGS)
13 if (args.ne.'') call abort
14 I = -1
15 CALL GETARG(I,ARGS)
16 if (args.ne.'') call abort
17 ! Assume we won't have been called with more that 4 args.
18 I = 4
19 CALL GETARG(I,ARGS)
20 if (args.ne.'') call abort
21 I = 1000
22 CALL GETARG(I,ARGS)
23 if (args.ne.'') call abort
24 end