ncm@zembu.com (Nathan Myers) writes:
> Yacc and yacc-like programs are most useful when the target grammar (or
> your understanding of it) is not very stable. With Yacc you can make
> sweeping changes much more easily; big changes can be a lot of work in
> a hand-coded parser.
And, in fact, this is precisely the killer reason why we will not switch
to a handwritten parser anytime in the foreseeable future. Postgres'
grammar is NOT stable. Compare the gram.y files for any two recent
releases. I foresee changes at least as large in upcoming releases,
btw, as we implement more of SQL92/99 and drop ancient PostQuel-isms.
I have some interest in proposals to switch to a better parser-generator
tool than yacc ... but yacc has the advantages of being widely
available and widely understood. You'd need a pretty significant
improvement over yacc to make it worth switching.
regards, tom lane