Re: review: psql: edit function, show function commands patch - Mailing list pgsql-hackers

From Pavel Stehule
Subject Re: review: psql: edit function, show function commands patch
Date
Msg-id AANLkTikJ2xotRT4Qqai6+PtcKqA07hgOo0R9aYydY7p7@mail.gmail.com
Whole thread Raw
In response to Re: review: psql: edit function, show function commands patch  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-hackers
Hello

2010/8/8 Tom Lane <tgl@sss.pgh.pa.us>:
> Pavel Stehule <pavel.stehule@gmail.com> writes:
>> updated patch attached
>
> What exactly is the point of the \sf command?  It seems like quite a lot
> of added code for a feature that nobody has requested, and whose
> definition is about as ad-hoc as could be.  Personally I'd much sooner
> use \ef for looking at a function definition.  I think if \sf had been
> submitted as a separate patch, rather than being snuck in with a feature
> people do want, it wouldn't be accepted.
>
> The current patch doesn't even compile warning-free :-(
>
> command.c: In function `exec_command':
> command.c:559: warning: `lineno' might be used uninitialized in this function
> command.c: In function `editFile':
> command.c:1729: warning: `editor_lineno_switch' might be used uninitialized in this function
>

This warnings depends on gcc version, probably :(. On new fedora I see
nothing. So updated patch attached - these variables are initialised
in declaration now.

Regards

Pavel Stehule

>
>                        regards, tom lane
>

Attachment

pgsql-hackers by date:

Previous
From: Pavel Stehule
Date:
Subject: Re: review: psql: edit function, show function commands patch
Next
From: Markus Wanner
Date:
Subject: Re: parallel quicksort