Re: What happen to the VARATT_SIZEP macro in version 8.3? - Mailing list pgsql-general

From Jaime Casanova
Subject Re: What happen to the VARATT_SIZEP macro in version 8.3?
Date
Msg-id 3073cc9b0808051436n1e04e437v80c5b1e878e7e872@mail.gmail.com
Whole thread Raw
In response to What happen to the VARATT_SIZEP macro in version 8.3?  ("Don Pannese" <don.pannese@hds.com>)
List pgsql-general
On 8/5/08, Don Pannese <don.pannese@hds.com> wrote:
>
> I have C code which defines some user defined postgres functions. This code
> has been used with Postgres version 7.4 and it uses the VARATT_SIZEP macro.
>

seems that macro was deprecated in 8.3... this is the commit that removed it:
http://archives.postgresql.org/pgsql-committers/2007-02/msg00517.php

The new comment says:
!  * TOASTed.  Generally, only the code closely associated with TOAST logic
!  * should mess directly with struct varattrib or use the VARATT_FOO macros.

Why you need that macro at all? Now, of you really need it maybe you
can make your own wrapper in ine of your includes:

#define VARATT_SIZEP(_PTR)        \
        VARATT_SIZEP_DEPRECATED(PTR)


--
regards,
Jaime Casanova
Soporte y capacitación de PostgreSQL
Guayaquil - Ecuador
Cel. (593) 87171157

pgsql-general by date:

Previous
From: Andrew Sullivan
Date:
Subject: Re: replication only
Next
From: Glyn Astill
Date:
Subject: Re: What happen to the VARATT_SIZEP macro in version 8.3?