зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1108382 - Part 4: Do not use non-standard flag argument of String.prototype.replace in build/pgo/. r=jandem
This commit is contained in:
Родитель
c8a5e780ae
Коммит
0a48a9926a
|
@ -1741,14 +1741,14 @@ ilen = dnaInput.length;
|
|||
dnaInput = dnaInput.replace(/>.*\n|\n/g,"")
|
||||
clen = dnaInput.length
|
||||
|
||||
var dnaOutputString;
|
||||
var dnaOutputString = "";
|
||||
|
||||
for(i in seqs)
|
||||
dnaOutputString += seqs[i].source + " " + (dnaInput.match(seqs[i]) || []).length + "\n";
|
||||
// match returns null if no matches, so replace with empty
|
||||
|
||||
for(k in subs)
|
||||
dnaInput = dnaInput.replace(k, subs[k], "g")
|
||||
dnaInput = dnaInput.replace(k, subs[k]) // FIXME: Would like this to be a global substitution in a future version of SunSpider.
|
||||
// search string, replacement string, flags
|
||||
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче