How can I return a pointer to a use structure from a function - Mailing list pgsql-hackers

From Chongbing Liu
Subject How can I return a pointer to a use structure from a function
Date
Msg-id Pine.LNX.4.58.0312191228060.20781@clink
Whole thread Raw
In response to Re: How can I return a NULL value from a function?  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: How can I return a pointer to a use structure from a function
List pgsql-hackers

Thank you very much for your help.

In V1 function calling convention, there are micros
like PG_RETURN_TEXT_P and so on.  Most of them are
used to return values of the built-in datatypes.

If I want the XXX_in function (for my own data type)
to return a pointer to a particular structure, what
micro should I use? i.e., how should I organize the
return value?

Thank you and wish you and everybody a merry Christmas.

Chongbing


On Fri, 19 Dec 2003, Tom Lane wrote:

> Chongbing Liu <cliu@cs.nmsu.edu> writes:
> > Hello, can you please tell me how to return a NULL value
> > from a function?
>
> You can't unless you use the V1 function calling convention.  See the
> programmer's guide.
>
>             regards, tom lane
>
> ---------------------------(end of broadcast)---------------------------
> TIP 4: Don't 'kill -9' the postmaster
>


pgsql-hackers by date:

Previous
From: Josh Berkus
Date:
Subject: Re: Issue with Linux+Pentium SMP Context Switching
Next
From: Manfred Spraul
Date:
Subject: Re: Issue with Linux+Pentium SMP Context Switching