2 ! PR43409 I/O: INQUIRE for SIZE does not work.
4 character(30) :: aname
= "noname"
7 open(25, file
="testfile_inquire_size", status
="replace", access
="stream", form
="unformatted")
9 write(25) i
, "abcdefghijklmnopqrstuvwxyz"
11 ! Gfortran implicitly flushes the buffer when doing a file size
12 ! inquire on an open file.
15 inquire(unit
=25, named
=is_named
, name
=aname
, size
=i
)
16 if (.not
.is_named
) call abort
17 if (aname
/= "testfile_inquire_size") call abort
18 if (i
/= 3000) call abort
20 inquire(file
="testfile_inquire_size", size
=i
)
21 if (.not
.is_named
) call abort
22 if (aname
/= "testfile_inquire_size") call abort
23 if (i
/= 3000) call abort
25 close(25, status
="delete")
26 inquire(file
="testfile_inquire_size", size
=i
)
27 if (i
/= -1) call abort