Error location in Python: where the mutants hide

Joshua Charles Campbell, Abram Hindle, José Nelson Amaral · 2015

Dynamic scripting programming languages present a unique challenge to software engineering tools that depend on static analysis. Dynamic languages do not benefit from the full lexical and syntax analysis provided by compilers and static analysis tools. Prior work exploited a statically typed language (Java) and a simple \(n\)-gram language model to find syntax-error locations in programs. This work investigates whether \(n\)-gram-based error location on source code written in a dynamic language is effective without static analysis or compilation. UnnaturalCode.py is a syntax-error locator developed for the Python programming language. The UnnaturalCode.py approach is effective on Python code, but faces significantly more challenges than its Java counterpart did. UnnaturalCode.py generalizes the success of previous statically-typed approaches to a dynamically-typed language.

Read the paper · More papers on PaperTik