aboutsummaryrefslogtreecommitdiff
path: root/gcc/testsuite/gfortran.dg/unsigned_4.f90
blob: 46b08a3e81f62ebacfcd114b51187238063d4f73 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
! { dg-do run }
! { dg-options "-funsigned" }
! Test some basic formatted I/O.

program main
  unsigned :: u
  open (10,status="scratch")
  write (10,'(I4)') 1u
  write (10,'(I4)') -1
  rewind 10
  read (10,'(I4)') u
  if (u /= 1u) error stop 1
  read (10,'(I4)') u
  if (u /= 4294967295u) error stop 2
end program main