OSDN Git Service

I'm continuing to work on cleaning up code in psql. As things appear
authorBruce Momjian <bruce@momjian.us>
Thu, 20 Mar 2003 06:43:35 +0000 (06:43 +0000)
committerBruce Momjian <bruce@momjian.us>
Thu, 20 Mar 2003 06:43:35 +0000 (06:43 +0000)
commitadd932ee91b9ca78c1a0647487cd6d2a680c4f12
treeabb208bec97099a408ead6d6c5b0f0929c459a2d
parent1b3d4cefe8e025a40e3a795f311d4711178366e9
I'm continuing to work on cleaning up code in psql.  As things appear
now, my changes seem to work.  Some possible minor bugs got squished
on the way but I can't be sure without more feedback from people who
really put the code to the test.

The new patch mostly simplifies variable handling and reduces code
duplication.  Changes in the command parser eliminate some redundant
variables (boolean state + depth counter), replaces some
"else if" constructs with switches, and so on.  It is meant to be
applied together with my previous patch, although I hope they don't
conflict; I went back to the CVS version for this one.

One more thing I thought should perhaps be changed: an IGNOREEOF
value of n will ignore only n-1 EOFs.  I didn't want to touch this
for fear of breaking existing applications, but it does seem a tad
illogical.

Jeroen T. Vermeulen
src/bin/psql/command.c
src/bin/psql/common.c
src/bin/psql/common.h
src/bin/psql/input.c
src/bin/psql/large_obj.c
src/bin/psql/mainloop.c
src/bin/psql/prompt.c
src/bin/psql/startup.c
src/bin/psql/variables.c
src/bin/psql/variables.h