Rexstepper: a Reference Debugger for JavaScript Regular Expressions

Lúıs Almeida, Miguel Gonzaga, José Fragoso Santos, Rui Abreu · 2023

Regular expressions are notoriously difficult to get right, with developers often having to resort to trial-and-error approaches. Even so, little attention has been given by the re search community to the development of effective debugging tools for regular expressions. We present RexStepper, a reference debugger for troubleshooting JavaScript regular expressions in the browser. Rexstepper is implemented on top of Rexref, a trusted reference implementation of JavaScript (ECMAScript 5) regular expressions, which works by transpiling the given reg-ular expression to a JavaScript function that recognises its expansions. We demonstrate the usefulness of Rexstepper by successfully using it to troubleshoot a benchmark of 18 faulty regular expressions obtained from the Stack Overflow and Stack Exchange websites.

Read the paper · More papers on PaperTik