Skip site navigation (1) Skip section navigation (2)

Re: writing new regexp functions

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Jeremy Drake <pgsql(at)jdrake(dot)com>
Cc: PostgreSQL Hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: writing new regexp functions
Date: 2007-02-02 00:41:39
Message-ID: 1875.1170376899@sss.pgh.pa.us (view raw or flat)
Thread:
Lists: pgsql-hackerspgsql-patches
Jeremy Drake <pgsql(at)jdrake(dot)com> writes:
> Is there some specific reason that these functions are static,

Yeah: not cluttering the global namespace.  I'm not excited about
exporting everything that anybody could possibly want access to;
that just makes it harder to maintain the code.  When you see a
static function, you know that you don't have to look further than
the current file to understand how it's used.  When you see a global
function, the difficulty of knowing how it's used is an order of
magnitude higher, maybe more.  What's more, if you want to change it
then you have to worry about the possible side-effects on unknown
non-core code that might be calling it.

Is there a reason for not putting your new code itself into regexp.c?

			regards, tom lane

In response to

Responses

pgsql-hackers by date

Next:From: Kate FDate: 2007-02-02 00:53:35
Subject: Function proposal to find the type of a datum
Previous:From: Koichi SuzukiDate: 2007-02-02 00:39:38
Subject: Re: [HACKERS] Full page writes improvement

pgsql-patches by date

Next:From: Tom LaneDate: 2007-02-02 01:03:27
Subject: Re: [HACKERS] Full page writes improvement
Previous:From: Koichi SuzukiDate: 2007-02-02 00:39:38
Subject: Re: [HACKERS] Full page writes improvement

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group