blob: 15d70215020158cbb2348231b21d59795b8efc27 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
|
! { dg-do run }
! { dg-options "-fbounds-check" }
! { dg-shouldfail "Substring out of bounds check" }
! PR fortran/27588
program bound_check
character*10 zz
i = 2
j = i+9
zz = ' '
zz(i:j) = 'abcdef'
print * , zz
end
! { dg-output "At line 10.*Substring out of bounds: upper bound \\(11\\) of 'zz' exceeds string length" }
|