Program analysis tools used in software maintenance must be robust and ought to be accurate. Many data-driven parsing approaches developed for natural languages are robust and have quite high accuracy when applied to parsing of software. We show this for the programming languages Java, C/C++, and Python. Further studies indicate that post-processing can almost completely remove the remaining errors. Finally, the training data for instantiating the generic data-driven parser can be generated automatically for formal languages, as opposed to the manually development of treebanks for natural languages. Hence, our approach could improve the robustness of software maintenance tools, probably without showing a significant negative effect on their accuracy.
Nilson et al. REF claim that data-driven parsing approaches developed for natural languages are robust and have quite high accuracy when applied to parsing of software.
Parsing Formal Languages using Natural Language Parsing Techniques
Proceedings of the 11th International Conference on Parsing Technologies (IWPT’09)
Computer Science