Correctly parse regular expressions with the 'm' and 'y' flags. bug 378486, r=brendan
git-svn-id: svn://10.0.0.236/trunk@226633 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
parent
71599d9c82
commit
0c150c2b79
@ -161,7 +161,7 @@ Tokenizer.prototype = {
|
||||
token.type = STRING;
|
||||
token.value = eval(match[0]);
|
||||
} else if (this.scanOperand &&
|
||||
(match = /^\/((?:\\.|[^\/])+)\/([gi]*)/(input))) {
|
||||
(match = /^\/((?:\\.|[^\/])+)\/([gimy]*)/(input))) {
|
||||
token.type = REGEXP;
|
||||
token.value = new RegExp(match[1], match[2]);
|
||||
} else if ((match = opRegExp(input))) {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user