3 ! PR 42167: [OOP] SELECT TYPE with function return value
5 ! Contributed by Damian Rouson <damian@rouson.net>
11 real ,dimension(:) ,allocatable :: f
18 function total(lhs,rhs)
19 class(bar) ,intent(in) :: lhs
20 class(bar) ,intent(in) :: rhs
21 class(bar) ,pointer :: total
24 allocate(bar :: total)
27 total%f = lhs%f + rhs%f