OpenCores
URL https://opencores.org/ocsvn/openrisc/openrisc/trunk

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [gcc/] [testsuite/] [gfortran.dg/] [is_iostat_end_eor_2.f90] - Blame information for rev 774

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 694 jeremybenn
! Check that we correctly simplify IS_IOSTAT_END and IS_IOSTAT_EOR.
2
! Not very useful, but required by the standards
3
!
4
! This test relies on the error numbers for END and EOR being -1 and -2.
5
! This is good to actual
6
!
7
! { dg-do compile }
8
!
9
 
10
  use iso_fortran_env, only : iostat_end, iostat_eor
11
  implicit none
12
 
13
  integer(kind=merge(4, 0, is_iostat_end(-1))) :: a
14
  integer(kind=merge(4, 0, is_iostat_end(-1_1))) :: b
15
  integer(kind=merge(4, 0, is_iostat_end(-1_2))) :: c
16
  integer(kind=merge(4, 0, is_iostat_end(-1_4))) :: d
17
  integer(kind=merge(4, 0, is_iostat_end(-1_8))) :: e
18
 
19
  integer(kind=merge(4, 0, is_iostat_eor(-2))) :: f
20
  integer(kind=merge(4, 0, is_iostat_eor(-2_1))) :: g
21
  integer(kind=merge(4, 0, is_iostat_eor(-2_2))) :: h
22
  integer(kind=merge(4, 0, is_iostat_eor(-2_4))) :: i
23
  integer(kind=merge(4, 0, is_iostat_eor(-2_8))) :: j
24
 
25
  integer(kind=merge(0, 4, is_iostat_eor(-1))) :: k
26
  integer(kind=merge(0, 4, is_iostat_end(-2))) :: l
27
 
28
  integer(kind=merge(0, 4, is_iostat_eor(0))) :: m
29
  integer(kind=merge(0, 4, is_iostat_end(0))) :: n
30
 
31
  integer(kind=merge(4, 0, is_iostat_end(0))) :: o ! { dg-error "not supported for type" }
32
  integer(kind=merge(4, 0, is_iostat_eor(0))) :: p ! { dg-error "not supported for type" }
33
 
34
  integer(kind=merge(4, 0, is_iostat_eor(iostat_eor))) :: q
35
  integer(kind=merge(4, 0, is_iostat_end(iostat_end))) :: r
36
  integer(kind=merge(0, 4, is_iostat_end(iostat_eor))) :: s
37
  integer(kind=merge(0, 4, is_iostat_eor(iostat_end))) :: t
38
 
39
  end

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.