Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(14)

Unified Diff: src/string.js

Issue 4483001: Fix issue 924 - splitting the empty string. (Closed)
Patch Set: Created 10 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | test/mjsunit/string-split.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/string.js
diff --git a/src/string.js b/src/string.js
index a75ccf0fa54f0747223e7be60845cfbd6af95d95..1f2255aa196dd99d7d09dd913cf2c2a001db3ac4 100644
--- a/src/string.js
+++ b/src/string.js
@@ -567,7 +567,7 @@ function StringSplit(separator, limit) {
%_Log('regexp', 'regexp-split,%0S,%1r', [subject, separator]);
if (length === 0) {
- if (splitMatch(separator, subject, 0, 0) != null) {
+ if (DoRegExpExec(separator, subject, 0, 0) != null) {
return [];
}
return [subject];
« no previous file with comments | « no previous file | test/mjsunit/string-split.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698