"Kevin Grittner" writes:
> ...
> We were able to get to much cleaner code by rewriting the parser to
> have a "dumb" phase to get the overall structure into an AST, and then
> use a tree-walker phase to do all the lookups and type resolution
> after we had the rough structure, writing another AST
Tom Lane wrote:
> One problem that wasn't obvious when I started is that if you are
> trying to use a reentrant lexer, Bison insists on including its
> YYSTYPE union in the call signature of the lexer. Of course,
> YYSTYPE means different things to the core grammar and plpgsql's
> grammar. I
Alvaro Herrera writes:
> Tom Lane wrote:
>> ... I spent a fair amount of time trying to work around that
>> by eliminating uses of "yytext" in plpgsql, and mostly succeeded, but
>> there are still some left. (Some of the remaining regression failures are
>> error messages that point at the wrong
Tom Lane wrote:
> Another pretty serious issue is that the current plpgsql lexer treats
> various sorts of qualified names as single tokens. I had thought this
> could be worked around in the interface layer by doing more lookahead.
> You can do that, and it mostly works, but it's mighty tedious.
I've spent the past several days working on the project I suggested here:
http://archives.postgresql.org/message-id/18653.1239741...@sss.pgh.pa.us
of getting rid of plpgsql's private lexer and having it use the core
lexer instead. I've run out of time for that and need to go focus on
commitfest re