Abstract

The motivation of adopting the Generalized LR (GLR) parsing algorithm to construct parsers for programming languages is presented. A multi-level strategy for optimizing a GLR parser and the necessary runtime control mechanisms are introduced to the GLR parsers for flexible disambiguation and for invoking semantic actions attached to grammar rules while avoiding the delayed semantic action problem. The algorithm has been implemented in VPGE, a visual parser generation environment. Experimental results show that the speed of the generated GLR parsers is comparable to LALR(1) parsers generated by GNU's Bison when parsing deterministic programming languages.

Talk to us

Join us for a 30 min session where you can share your feedback and ask us any queries you have

Schedule a call

Disclaimer: All third-party content on this website/platform is and will remain the property of their respective owners and is provided on "as is" basis without any warranties, express or implied. Use of third-party content does not indicate any affiliation, sponsorship with or endorsement by them. Any references to third-party content is to identify the corresponding services and shall be considered fair use under The CopyrightLaw.