regex - JavaScript: detection of regular expression in source code -
i need parse javascript source code , match regular expressions of regular expression :). first tried regular expression:
(?:\/.*\/)
but not work if regular expression contains slash, in next source code
while (line.match(/[+*/]/)) line = line.replace(/([+*/])\s(\d+)\s(\d+)/, function (s, op, a, b) { return operators[op](+a, +b); });
i don`t know how keep possibilities in 1 regular expression. there way match regular expression in javascript source code using regular expressions?
Comments
Post a Comment