1! { dg-do run } 2! 3! PR fortran/60286 4! 5! Contributed by Alexander Vogt 6! 7program test_inquire 8 use, intrinsic :: ISO_Fortran_env 9 implicit none 10 character(len=20) :: s_read, s_write, s_readwrite 11 12 inquire(unit=input_unit, read=s_read, write=s_write, & 13 readwrite=s_readwrite) 14 if (s_read /= "YES" .or. s_write /= "NO" .or. s_readwrite /="NO") then 15 call abort() 16 endif 17 18 inquire(unit=output_unit, read=s_read, write=s_write, & 19 readwrite=s_readwrite) 20 if (s_read /= "NO" .or. s_write /= "YES" .or. s_readwrite /="NO") then 21 call abort() 22 endif 23 24 inquire(unit=error_unit, read=s_read, write=s_write, & 25 readwrite=s_readwrite) 26 if (s_read /= "NO" .or. s_write /= "YES" .or. s_readwrite /="NO") then 27 call abort() 28 endif 29end program test_inquire 30