Roman Neuhauser <neuhauser(at)sigpipe(dot)cz> writes:
> Looking at src/pl/plpgsql/src/pl_exec.c for the first time, is it a problem
> of make_tuple_from_row() not accounting for nested composite types?
Looks that way. I've committed a fix to HEAD. I'm not sure how hard
it'd be to fix 8.0.
regards, tom lane