> You may not even need to add any fields to FuncCallContext --- consider
> passing the fcinfo pointer to the callback, rather than passing the
> FuncCallContext pointer.
Dept. of second thoughts: better pass the flinfo pointer, instead.
fcinfo might point to temporary space on the stack.
regards, tom lane