gcc/testsuite/gfortran.dg/forall_17.f90
raw| 1 | ! { dg-do compile } |
| 2 | ! { dg-options "-ffrontend-optimize" } |
| 3 | ! PR fortran/66385 - this used to ICE |
| 4 | ! Original test case by Mianzhi Wang |
| 5 | program test |
| 6 | double precision::aa(30) |
| 7 | double precision::a(3,3),b |
| 8 | b=1d0 |
| 9 | forall(i=1:3) |
| 10 | a(:,i)=b*[1d0,2d0,3d0] |
| 11 | end forall |
| 12 | |
| 13 | forall(i=1:10) |
| 14 | aa(10*[0,1,2]+i)=1d0 |
| 15 | end forall |
| 16 | |
| 17 | end program |