File: demo15.f90

package info (click to toggle)
fortran-cli2 3.2.0-2
  • links: PTS, VCS
  • area: main
  • in suites:
  • size: 25,856 kB
  • sloc: f90: 6,172; javascript: 3,423; makefile: 188; sh: 25
file content (23 lines) | stat: -rwxr-xr-x 639 bytes parent folder | download | duplicates (8)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
program demo15
!> @(#) strict mode
!!
!! In strict mode short single-character names may be bundled but it is
!! required that a single dash is used, where normally single and double
!! dashes are equivalent.
!!
!!     demo15 -o -t -x
!!     demo15 -otx
!!     demo15 -xto      
!!
!! Only Boolean keynames may be bundled together
!!
use M_CLI2,  only : set_args, lget, set_mode
implicit none
character(len=*),parameter :: all='(*(g0))'

   print *,'demo15: strict mode'

   call set_mode('strict')
   call set_args(' -o F -t F -x F --ox F')
   print all,'o=',lget('o'),' t=',lget('t'),' x=',lget('x'),' ox=',lget('ox')
end program demo15