--- Comment #5 from neil.n.carlson at gmail dot com ---
Here's a more complete example that avoids the ICE.

It gives correct results with 6.3:
           5 fubar
           5 fubar

But incorrect results with 7.0:
           5 fubar

program main

  class(*), pointer :: x, y
  allocate(x, source='fubar')

  y => foobar(x)

  select type (y)
  type is (character(*))
    print *, len(y), y
  end select


  function foobar(bar) result(foo)
    class(*), pointer :: foo, bar
    foo => bar
    select type (foo)
    type is (character(*))
      print *, len(foo), foo
    end select
  end function

end program

Reply via email to