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

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-stable/] [gcc-4.5.1/] [gcc/] [testsuite/] [gfortran.dg/] [do_check_2.f90] - Rev 862

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

! { dg-do run }
! { dg-options "-fcheck=do" }
! { dg-shouldfail "DO check" }
!
! PR fortran/34656
! Run-time check for modifing loop variables
!
program test
  implicit none
  integer :: i,j
  do i = 1, 10
    call modLoopVar(i)
  end do
contains
  subroutine modLoopVar(i)
    integer :: i
    i = i + 1
  end subroutine modLoopVar
end program test
! { dg-output "Fortran runtime error: Loop variable has been modified" }

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

powered by: WebSVN 2.1.0

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