Re: linked list rewrite - Mailing list pgsql-hackers

From Tom Lane
Subject Re: linked list rewrite
Date
Msg-id 28046.1080071998@sss.pgh.pa.us
Whole thread Raw
In response to Re: linked list rewrite  (Bruce Momjian <pgman@candle.pha.pa.us>)
Responses Re: linked list rewrite
List pgsql-hackers
Bruce Momjian <pgman@candle.pha.pa.us> writes:
> Neil Conway wrote:
>> Tom objected to changing the names:

> I agree a renaming of list functions is good.  If we had kept the
> original Berkeley code as-is, we would have a lot fewer developers
> today.  :-)  Making drastic cleanups is often worthwile.

I would be satisfied if we kept the names of the core,
most-commonly-used functions the same.  I would put lfirst, lnext,
lcons, lappend, length, maybe member into the category of names
I don't want to change.  Attaching "_int" and "_oid" to those for the
related functions is okay.

If we go in that direction then the common prefix would be just "l"
and not "list_", which seems a good idea to me on grounds of brevity.
Looking over Neil's proposal again, one of the things that bugged me
about it was that the function names were overly verbose.  That's okay
for stuff you don't see often, but the common list functions are *all
over* the backend.  You can't really claim that developers will be
unfamiliar with them.  Making those names longer won't buy us anything
except sooner onset of carpal tunnel syndrome.
        regards, tom lane


pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: [COMMITTERS] pgsql-server/ oc/src/sgml/ref/alter_table.sgml ...
Next
From: Bruce Momjian
Date:
Subject: Re: linked list rewrite