! { dg-do compile } ! Various problems found in solving PR 31610: character :: c ! Check that the length of an uninitialized scalar is handled ! properly. write(*,*) transfer("ab", c) ! Check that we don't have problems with constant function arguments. write(*,*) transfer (merge ( (/ "a", "b" /), "c", (/ .true., .false. /) ), & "ac" ) ! Check that character lengths get set correctly when the result ! is an array and the mold is a scalar. write(*,*) transfer("ABCDE", "x", 5) end