> > Attached is an updated patch, giving the following output.
> > Oh, one other thing: dropping externs into random modules unrelated to
> > their source module is completely awful programming style, because there
> > is nothing preventing incompatible declarations. Put those externs in
> > keywords.h instead.
> > I suspect you have ignored a compiler warning
> > about not declaring pg_get_keywords itself, too --- it should be
> > extern'd in builtins.h.
> No, no warning (I'm using VC++ today) - but fixed anyway.
> Update attached, including corrected docs. Note to self - proof read
> docs *after* putting the kids to bed in future.
Here are some comments from me:
a) Changed "localised" to "localized" to be consistent with the references
elsewhere in the same file.
b) I wonder if we need the default case in the switch statement at all,
since we are scanning the statically populated ScanKeywords array with
proper category values for each entry.
c) There was a warning during compilation since we were assigning a const
pointer to a char pointer
values = ScanKeywords[funcctx->call_cntr].name;
d) oid 2700 has been claimed by another function in the meanwhile. Modified
it to 2701.
DATA(insert OID = 2701 ( pg_get_keywords PGNSP PGUID 12 10 400 f f t t s
e) I was wondering why pronargs is set to 0 above. But I see other functions
doing the same, so its ok I guess for such kinds of usages.
PFA, version 4 of this patch with a,c and d taken care of.
In response to
pgsql-patches by date
|Next:||From: Marko Kreen||Date: 2008-07-03 08:15:10|
|Subject: Re: [PATCHES] pg_dump lock timeout|
|Previous:||From: Joe Conway||Date: 2008-07-03 04:03:39|
|Subject: Re: Re: [BUGS] BUG #4203: perform dblink() in begin/exception
returns wrong SQLSTATE code|