2 ! PR 32217 - unpack used to crash at runtime with a zero-sized
3 ! array. Test case submitted by Jaroslav Hajek.
6 integer,parameter:: rp = kind(1.d0),na = 6
7 real(rp),allocatable:: hhe(:,:,:),hhc(:,:,:),dv(:)
10 allocate(hhe(nhh,2,2))
11 ndv = 2*na + count(hhe /= 0)
12 allocate(hhc(nhh,2,2),dv(ndv))
13 hhc = unpack(dv(2*na+1:),hhe /= 0._rp,0._rp)
14 end program bug_report