VARSIZE - why omit VARLEN?

From: Andrew Chernow <ac(at)esilo(dot)com>
To: PostgreSQL Hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: VARSIZE - why omit VARLEN?
Date: 2009-01-18 02:27:18
Message-ID: 49729386.9050207@esilo.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Any objections adding the below to postgres.h?

#define VARLEN(PTR) (VARSIZE(PTR) - VARHDRSZ)

It adds a little more abstraction and cleans up userland code.

--
Andrew Chernow
eSilo, LLC
every bit counts
http://www.esilo.com/

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2009-01-18 06:02:01 Re: pg_dump versus views and opclasses
Previous Message Gregory Stark 2009-01-18 01:12:36 Re: Fixes for compiler warnings