URL
https://opencores.org/ocsvn/openrisc_2011-10-31/openrisc_2011-10-31/trunk
Subversion Repositories openrisc_2011-10-31
[/] [openrisc/] [trunk/] [gnu-src/] [gcc-4.2.2/] [gcc/] [testsuite/] [gfortran.dg/] [impure_assignment_1.f90] - Rev 165
Go to most recent revision | Compare with Previous | Blame | View Log
! { dg-do compile }
! Tests fix for PR25059, which gave and ICE after error message
! Contributed by Joost VandeVondele <jv244@cam.ac.uk>
MODULE M1
TYPE T1
INTEGER :: I
END TYPE T1
INTERFACE ASSIGNMENT(=)
MODULE PROCEDURE S1
END INTERFACE
CONTAINS
SUBROUTINE S1(I,J)
TYPE(T1), INTENT(OUT):: I
TYPE(T1), INTENT(IN) :: J
I%I=J%I**2
END SUBROUTINE S1
END MODULE M1
USE M1
CONTAINS
PURE SUBROUTINE S2(I,J)
TYPE(T1), INTENT(OUT):: I
TYPE(T1), INTENT(IN) :: J
I=J ! { dg-error "must be PURE" }
END SUBROUTINE S2
END
Go to most recent revision | Compare with Previous | Blame | View Log