5 ! Don't auto-deallocatable scalar character allocatables.
8 character(len
=5), allocatable
:: str
11 if(str
/= '1bcde') STOP 1
12 call sub(str
,len(str
))
13 if(str
/= '1bcde') STOP 2
14 call subOUT(str
,len(str
))
15 if (len(str
) /= 5) STOP 3
16 if(allocated(str
)) STOP 4
20 character(len
=n
), allocatable
:: x
21 if(len(x
) /= 5) STOP 5
22 if(x
/= '1bcde') STOP 6
24 subroutine subOUT(x
,n
)
26 character(len
=n
), allocatable
,intent(out
) :: x
27 if(allocated(x
)) STOP 7
28 if(len(x
) /= 5) STOP 8