Robert Haas <robertmh...@gmail.com> writes:
> On Thu, Aug 25, 2011 at 5:12 PM, Tom Lane <t...@sss.pgh.pa.us> wrote:
>> ISTM the general rule ought to be that we attempt to substitute for a
>> colon-construct regardless of where it appears within an argument, as
>> long as it's not within quotes.

> My main thought is that I remember this code being pretty awful -
> especially with respect to error handling - when I looked at it.  A
> lot of dubious behaviors were more or less compelled by the
> impossibility of bailing out at an arbitrary point a la ereport().  At
> least, barring a drastic refactoring of the code, which might not be a
> bad idea either.

What I had in mind to do was just to rearrange the flex rules --- the
issues that I called out have to do with dubious choices about when to
transition between different lexer states.

I agree that the error handling isn't terribly friendly in unexpected
cases like there not being a connection available to determine the
literal-quoting rules, but that's not what I'm on about here.  I'm
just after consistent variable-expansion behavior in normal operation.

                        regards, tom lane

-- 
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

Reply via email to