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

Issue 515183002: Make String.fromCharCodes take start/end. (Closed)

Created:
6 years, 3 months ago by Lasse Reichstein Nielsen
Modified:
6 years, 2 months ago
CC:
reviews_dartlang.org, vm-dev_dartlang.org
Visibility:
Public.

Description

Make String.fromCharCodes take start/end. This avoids having to make a sublist of a list of character codes before passing it to String.fromCharCodes. new String.fromCharCodes(codes.sublist(start, end)) becomes just new String.fromCharCodes(codes, start, end) R=floitsch@google.com, sgjesse@google.com Committed: https://code.google.com/p/dart/source/detail?r=40672

Patch Set 1 #

Patch Set 2 : Typo in dart2js code. #

Patch Set 3 : Remove warnings #

Patch Set 4 : More tests. #

Patch Set 5 : Bug in dart2js version. #

Total comments: 19

Patch Set 6 : Address comments. #

Patch Set 7 : Don't say that end must be greater than start. Passing the actual length should be the same as pass… #

Total comments: 11

Patch Set 8 : Address comments. #

Patch Set 9 : Merge to tip of tree. #

Total comments: 3
Unified diffs Side-by-side diffs Delta from patch set Stats (+370 lines, -79 lines) Patch
M runtime/lib/string.cc View 1 2 3 4 5 6 7 8 2 chunks +74 lines, -21 lines 0 comments Download
M runtime/lib/string_patch.dart View 1 2 3 4 5 6 7 4 chunks +47 lines, -39 lines 0 comments Download
M runtime/vm/bootstrap_natives.h View 1 2 3 4 5 6 7 8 1 chunk +2 lines, -2 lines 0 comments Download
M sdk/lib/_internal/compiler/js_lib/core_patch.dart View 1 2 3 4 5 6 7 1 chunk +25 lines, -4 lines 0 comments Download
M sdk/lib/convert/latin1.dart View 1 chunk +1 line, -5 lines 0 comments Download
M sdk/lib/convert/utf.dart View 1 2 3 4 5 6 7 1 chunk +1 line, -6 lines 0 comments Download
M sdk/lib/core/string.dart View 1 2 3 4 5 6 1 chunk +10 lines, -1 line 3 comments Download
M sdk/lib/internal/iterable.dart View 2 chunks +16 lines, -1 line 0 comments Download
A tests/corelib/string_fromcharcodes_test.dart View 1 2 3 4 5 1 chunk +194 lines, -0 lines 0 comments Download

Messages

Total messages: 14 (1 generated)
Lasse Reichstein Nielsen
lrn@google.com changed reviewers: + floitsch@google.com, sgjesse@google.com, srdjan@google.com
6 years, 3 months ago (2014-08-29 08:36:23 UTC) #1
Lasse Reichstein Nielsen
6 years, 3 months ago (2014-08-29 08:36:24 UTC) #2
floitsch
LGTM. https://codereview.chromium.org/515183002/diff/80001/runtime/lib/string.cc File runtime/lib/string.cc (right): https://codereview.chromium.org/515183002/diff/80001/runtime/lib/string.cc#newcode53 runtime/lib/string.cc:53: ASSERT(start <= end); Don't assert but check. https://codereview.chromium.org/515183002/diff/80001/runtime/lib/string.cc#newcode63 ...
6 years, 3 months ago (2014-08-29 11:13:21 UTC) #3
Søren Gjesse
lgtm https://codereview.chromium.org/515183002/diff/80001/runtime/lib/string_patch.dart File runtime/lib/string_patch.dart (right): https://codereview.chromium.org/515183002/diff/80001/runtime/lib/string_patch.dart#newcode72 runtime/lib/string_patch.dart:72: if (start < 0) start = 0; Why ...
6 years, 3 months ago (2014-08-29 11:16:04 UTC) #4
Lasse Reichstein Nielsen
PTAL srdjan https://codereview.chromium.org/515183002/diff/80001/runtime/lib/string.cc File runtime/lib/string.cc (right): https://codereview.chromium.org/515183002/diff/80001/runtime/lib/string.cc#newcode53 runtime/lib/string.cc:53: ASSERT(start <= end); On 2014/08/29 11:13:20, floitsch ...
6 years, 3 months ago (2014-09-02 07:57:05 UTC) #5
srdjan
https://codereview.chromium.org/515183002/diff/120001/runtime/lib/string.cc File runtime/lib/string.cc (right): https://codereview.chromium.org/515183002/diff/120001/runtime/lib/string.cc#newcode53 runtime/lib/string.cc:53: ASSERT(start <= end); Please explain in comment why you ...
6 years, 3 months ago (2014-09-17 15:31:59 UTC) #6
Lasse Reichstein Nielsen
https://codereview.chromium.org/515183002/diff/120001/runtime/lib/string.cc File runtime/lib/string.cc (right): https://codereview.chromium.org/515183002/diff/120001/runtime/lib/string.cc#newcode53 runtime/lib/string.cc:53: ASSERT(start <= end); Good point. It's probably safer to ...
6 years, 3 months ago (2014-09-18 09:03:01 UTC) #7
Lasse Reichstein Nielsen
Committed patchset #9 (id:160001) manually as 40672 (presubmit successful).
6 years, 2 months ago (2014-09-25 10:45:35 UTC) #8
sra1
https://codereview.chromium.org/515183002/diff/160001/sdk/lib/core/string.dart File sdk/lib/core/string.dart (right): https://codereview.chromium.org/515183002/diff/160001/sdk/lib/core/string.dart#newcode115 sdk/lib/core/string.dart:115: * has no effect. Most APIs with a start ...
6 years, 2 months ago (2014-09-25 19:58:25 UTC) #10
Lasse Reichstein Nielsen
https://codereview.chromium.org/515183002/diff/160001/sdk/lib/core/string.dart File sdk/lib/core/string.dart (right): https://codereview.chromium.org/515183002/diff/160001/sdk/lib/core/string.dart#newcode115 sdk/lib/core/string.dart:115: * has no effect. It is deliberate because the ...
6 years, 2 months ago (2014-09-25 20:01:08 UTC) #11
floitsch
https://codereview.chromium.org/515183002/diff/160001/sdk/lib/core/string.dart File sdk/lib/core/string.dart (right): https://codereview.chromium.org/515183002/diff/160001/sdk/lib/core/string.dart#newcode115 sdk/lib/core/string.dart:115: * has no effect. On 2014/09/25 20:01:08, Lasse Reichstein ...
6 years, 2 months ago (2014-09-25 20:08:46 UTC) #12
Lasse Reichstein Nielsen
On 2014/09/25 20:08:46, floitsch wrote: > https://codereview.chromium.org/515183002/diff/160001/sdk/lib/core/string.dart > File sdk/lib/core/string.dart (right): > > https://codereview.chromium.org/515183002/diff/160001/sdk/lib/core/string.dart#newcode115 > ...
6 years, 2 months ago (2014-09-26 06:02:19 UTC) #13
Lasse Reichstein Nielsen
6 years, 2 months ago (2014-10-06 11:25:03 UTC) #14
Message was sent while issue was closed.
Fixe din CL https://codereview.chromium.org/605213002

Powered by Google App Engine
This is Rietveld 408576698