Regular expressions are notoriously difficult to get right, with developers often resorting to trial-and-error approaches when fixing their faulty regular expressions. Even so, little attention has been given by the research 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 regular 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.
Sahar Badihi University of British Columbia, Canada, Khaled Ahmed University of British Columbia (UBC), Yi Li Nanyang Technological University, Julia Rubin University of British Columbia, Canada