Generalized Parsing and Term Rewriting: Semantics Driven Disambiguation

M.G.J. van den Brand, A.S. Klusener, L. Moonen, J.J. Vinju
2003 Electronical Notes in Theoretical Computer Science  
Generalized parsing technology provides the power and flexibility to attack realworld parsing applications. However, many programming languages have syntactical ambiguities that can only be solved using semantical analysis. In this paper we propose to apply the paradigm of term rewriting to filter ambiguities based on semantical information. We start with the definition of a representation of ambiguous derivations. Then we extend term rewriting with means to handle such derivations. Finally, we
more » ... apply these tools to some real world examples, namely C and COBOL. The resulting architecture is simple and efficient as compared to semantic directed parsing.
doi:10.1016/s1571-0661(05)82629-5 fatcat:lkyl7l4pwvaibc6czuj2j5qeza