41 lines · plain
1! RUN: %python %S/test_errors.py %s %flang_fc12 integer :: unit10 = 103 integer :: unit11 = 114 integer, parameter :: const_stat = 66665 6 integer(kind=1) :: stat17 integer(kind=8) :: stat88 9 character(len=55) :: msg10 11 close(unit10)12 close(unit=unit11, err=9, iomsg=msg, iostat=stat1)13 close(12, status='Keep')14 15 close(iostat=stat8, 11) ! nonstandard16 17 !ERROR: CLOSE statement must have a UNIT number specifier18 close(iostat=stat1)19 20 !ERROR: Duplicate UNIT specifier21 close(13, unit=14, err=9)22 23 !ERROR: Duplicate ERR specifier24 close(err=9, unit=15, err=9, iostat=stat8)25 26 !ERROR: Invalid STATUS value 'kept'27 close(status='kept', unit=16)28 29 !ERROR: Invalid STATUS value 'old'30 close(status='old', unit=17)31 32 !Ok: trailing spaces ignored33 close(status='keep ', unit=17)34 35 !ERROR: IOSTAT variable 'const_stat' is not definable36 !BECAUSE: '6666_4' is not a variable or pointer37 close(14, iostat=const_stat)38 399 continue40end41