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