OpenCores
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.5.1/] [gcc/] [testsuite/] [gfortran.dg/] [bounds_check_10.f90] - Blame information for rev 302

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 302 jeremybenn
! { dg-do run }
2
! { dg-options "-fbounds-check" }
3
! { dg-shouldfail "Different CHARACTER lengths" }
4
! PR fortran/33254: No bounds checking for array constructors
5
program array_char
6
implicit none
7
character (len=2) :: x, y
8
character (len=2) :: z(3)
9
x = "a "
10
y = "cd"
11
z = [y(1:1), y(1:1), x(1:len(trim(x)))]  ! should work
12
z = [trim(x), trim(y), "aaaa"] ! [ "a", "cd", "aaaa" ] should catch first error
13
end program array_char
14
 
15
! { dg-output "Different CHARACTER lengths .1/2. in array constructor" }

powered by: WebSVN 2.1.0

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