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

Subversion Repositories openrisc

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

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 694 jeremybenn
! { dg-do compile }
2
! Tests fix for PR25059, which gave and ICE after error message
3
! Contributed by Joost VandeVondele  
4
MODULE M1
5
 TYPE T1
6
  INTEGER :: I
7
 END TYPE T1
8
 INTERFACE ASSIGNMENT(=)
9
   MODULE PROCEDURE S1
10
 END INTERFACE
11
CONTAINS
12
   SUBROUTINE S1(I,J)
13
     TYPE(T1), INTENT(OUT):: I
14
     TYPE(T1), INTENT(IN) :: J
15
     I%I=J%I**2
16
   END SUBROUTINE S1
17
END MODULE M1
18
 
19
USE M1
20
CONTAINS
21
PURE SUBROUTINE S2(I,J)
22
     TYPE(T1), INTENT(OUT):: I
23
     TYPE(T1), INTENT(IN) :: J
24
     I=J                      ! { dg-error "is not PURE" }
25
END SUBROUTINE S2
26
END
27
! { dg-final { cleanup-modules "m1" } }
28
 

powered by: WebSVN 2.1.0

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