3 real, parameter :: C(5:10) = 5.0
4 real, dimension (:), allocatable
:: A
, B
9 real, dimension ( -1 : ), intent ( in
) :: A
10 integer, dimension ( 1 ) :: lb_B
12 allocate (B
, mold
= A
)
13 if (any (lbound (B
) /= lbound (A
))) stop 1
14 if (any (ubound (B
) /= ubound (A
))) stop 2
15 if (any (shape (B
) /= shape (A
))) stop 3
16 if (size (B
) /= size (A
)) stop 4
18 allocate (B
, mold
= C
)
19 if (any (lbound (B
) /= lbound (C
))) stop 5
20 if (any (ubound (B
) /= ubound (C
))) stop 6
21 if (any (shape (B
) /= shape (C
))) stop 7
22 if (size (B
) /= size (C
)) stop 8