2 ! { dg-options "-fbounds-check -fno-realloc-lhs" }
3 ! { dg-shouldfail "Incorrect extent in return value of UNPACK intrinsic in dimension 2: is 1, should be 2" }
5 integer, allocatable
, dimension(:) :: vector
6 integer, allocatable
, dimension(:,:) :: res
7 logical, allocatable
, dimension(:,:) :: mask
14 mask
= reshape((/ .TRUE
., .FALSE
., .FALSE
., .TRUE
. /),(/2,2/))
15 res
= unpack(vector
, mask
, 0)
18 ! { dg-output "Fortran runtime error: Incorrect extent in return value of UNPACK intrinsic in dimension 2: is 1, should be 2" }