PR inline-asm/84742
[official-gcc.git] / gcc / testsuite / gfortran.dg / backspace_4.f
blob8d28e6184f102edd7948f270170d987638fd23bc
1 ! { dg-do run }
2 ! PR25598 Error on repeated backspaces.
3 ! Derived from example given in PR by Dale Ranta
4 ! Contributed by Jerry DeLisle <jvdelisle@gcc.gnu.org>
5 integer data
6 data=-1
7 open(unit=11,status='scratch',form='unformatted')
8 write(11)data
9 read(11,end= 1000 )data
10 STOP 1
11 1000 continue
12 backspace 11
13 backspace 11
14 read(11,end= 1001 )data
15 1001 continue
16 if (data.ne.-1) STOP 1
17 close(11)
18 end