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

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [gcc/] [testsuite/] [gfortran.dg/] [derived_comp_array_ref_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
! { dg-do run }
2
! Tests the fix for PR31564, in which the actual argument to
3
! the call for set_bound was simplified when it should not be.
4
!
5
! Contributed by Michael Richmond 
6
!
7
MODULE cdf_aux_mod
8
  TYPE :: the_distribution
9
    INTEGER :: parameters(2)
10
  END TYPE the_distribution
11
  TYPE (the_distribution), PARAMETER :: the_beta = the_distribution((/99,999/))
12
CONTAINS
13
  SUBROUTINE set_bound(arg_name, test)
14
    INTEGER, INTENT (IN) :: arg_name, test
15
    if (arg_name .ne. test) call abort ()
16
  END SUBROUTINE set_bound
17
END MODULE cdf_aux_mod
18
 
19
MODULE cdf_beta_mod
20
CONTAINS
21
  SUBROUTINE cdf_beta(which, test)
22
    USE cdf_aux_mod
23
    INTEGER :: which, test
24
    CALL set_bound(the_beta%parameters(which), test)
25
  END SUBROUTINE cdf_beta
26
END MODULE cdf_beta_mod
27
 
28
  use cdf_beta_mod
29
  call cdf_beta (1, 99)
30
  call cdf_beta (2, 999)
31
end
32
! { dg-final { cleanup-modules "cdf_aux_mod cdf_beta_mod" } }

powered by: WebSVN 2.1.0

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