http://codereview.chromium.org/1207004/diff/1/2
File src/string.js (right):

http://codereview.chromium.org/1207004/diff/1/2#newcode535
src/string.js:535: var last_idx = regexp.lastIndex; // keep old
lastIndex
Use:
  var match = DoRegExpExec(regexp, s, 0);
  if (match) {
    lastMatchInfo = match;
    return match[CAPTURE0];
  }
  return -1;

This avoids building the result of the exec call, it avoids calling exec
(depending on RegExp.prototype.exec not being changed), and it avoids
hitting
the regexp exec cache (which may or may not be a good thing).

http://codereview.chromium.org/1207004

--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev

To unsubscribe from this group, send email to v8-dev+unsubscribegooglegroups.com or reply 
to this email with the words "REMOVE ME" as the subject.

Reply via email to