aboutsummaryrefslogtreecommitdiff
path: root/gcc/testsuite/gfortran.dg/newunit_3.f90
blob: 2500130fe6b3272737c02102bdba9ce51976c238 (plain)
1
2
3
4
5
6
7
! { dg-do run }
! PR48960 On ERROR newunit should not modify user variable.
program test_newunit
    integer :: st, un = 0
    open (newunit=un, file='nonexisting.dat', status='old', iostat=st)
    if (un /= 0) STOP 1
end program test_newunit