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

Issue 711003002: Add some ArgumentError and RangeError constructors that capture more information. (Closed)

Created:
6 years, 1 month ago by Lasse Reichstein Nielsen
Modified:
6 years, 1 month ago
Reviewers:
Søren Gjesse, sra1
CC:
reviews_dartlang.org, ricow1, nweiz
Visibility:
Public.

Description

Add some ArgumentError and RangeError constructors that capture more information. Switch some uses of RangeError.range to RangeError.index. Fix bug in Queue where elementAt allowed `length` as input. R=sgjesse@google.com Committed: https://code.google.com/p/dart/source/detail?r=41653

Patch Set 1 #

Total comments: 4
Unified diffs Side-by-side diffs Delta from patch set Stats (+231 lines, -85 lines) Patch
M pkg/typed_data/lib/typed_buffers.dart View 1 chunk +2 lines, -2 lines 0 comments Download
M pkg/typed_data/pubspec.yaml View 1 chunk +1 line, -1 line 0 comments Download
M sdk/lib/_internal/compiler/js_lib/native_typed_data.dart View 4 chunks +4 lines, -4 lines 0 comments Download
M sdk/lib/collection/queue.dart View 1 chunk +2 lines, -2 lines 0 comments Download
M sdk/lib/convert/ascii.dart View 1 chunk +2 lines, -2 lines 0 comments Download
M sdk/lib/core/errors.dart View 2 chunks +152 lines, -11 lines 4 comments Download
M sdk/lib/core/string.dart View 1 chunk +1 line, -1 line 0 comments Download
M sdk/lib/html/dart2js/html_dart2js.dart View 18 chunks +18 lines, -18 lines 0 comments Download
M sdk/lib/html/dartium/html_dartium.dart View 19 chunks +20 lines, -20 lines 0 comments Download
M sdk/lib/internal/list.dart View 1 chunk +1 line, -1 line 0 comments Download
M sdk/lib/svg/dart2js/svg_dart2js.dart View 5 chunks +5 lines, -5 lines 0 comments Download
M sdk/lib/svg/dartium/svg_dartium.dart View 5 chunks +5 lines, -5 lines 0 comments Download
M sdk/lib/web_sql/dart2js/web_sql_dart2js.dart View 1 chunk +1 line, -1 line 0 comments Download
M sdk/lib/web_sql/dartium/web_sql_dartium.dart View 1 chunk +1 line, -1 line 0 comments Download
M tests/corelib/queue_test.dart View 1 chunk +5 lines, -0 lines 0 comments Download
M tools/dom/scripts/systemhtml.py View 3 chunks +3 lines, -3 lines 0 comments Download
M tools/dom/scripts/systemnative.py View 6 chunks +8 lines, -8 lines 0 comments Download

Messages

Total messages: 11 (2 generated)
Lasse Reichstein Nielsen
6 years, 1 month ago (2014-11-10 11:37:43 UTC) #2
Søren Gjesse
lgtm
6 years, 1 month ago (2014-11-10 12:27:29 UTC) #3
Lasse Reichstein Nielsen
Committed patchset #1 manually as r41653 (presubmit successful).
6 years, 1 month ago (2014-11-11 07:56:04 UTC) #4
sra1
This change adds 4.3k to swarm. Is there a way to do this without so ...
6 years, 1 month ago (2014-11-11 20:04:17 UTC) #6
Lasse Reichstein Nielsen
On 2014/11/11 20:04:17, sra1 wrote: > This change adds 4.3k to swarm. > > Is ...
6 years, 1 month ago (2014-11-11 20:18:04 UTC) #7
sra1
On 2014/11/11 20:18:04, Lasse Reichstein Nielsen wrote: > On 2014/11/11 20:04:17, sra1 wrote: > > ...
6 years, 1 month ago (2014-11-11 21:45:22 UTC) #8
sra1
https://codereview.chromium.org/711003002/diff/1/sdk/lib/core/errors.dart File sdk/lib/core/errors.dart (right): https://codereview.chromium.org/711003002/diff/1/sdk/lib/core/errors.dart#newcode273 sdk/lib/core/errors.dart:273: int length]) = IndexError; Doesn't this forwarding incorrectly store ...
6 years, 1 month ago (2014-11-11 22:04:11 UTC) #9
Lasse Reichstein Nielsen
On 2014/11/11 21:45:22, sra1 wrote: > https://codereview.chromium.org/717823002/ saves ~400 bytes > If you are OK ...
6 years, 1 month ago (2014-11-12 07:21:38 UTC) #10
Lasse Reichstein Nielsen
6 years, 1 month ago (2014-11-12 07:38:06 UTC) #11
Message was sent while issue was closed.
https://codereview.chromium.org/711003002/diff/1/sdk/lib/core/errors.dart
File sdk/lib/core/errors.dart (right):

https://codereview.chromium.org/711003002/diff/1/sdk/lib/core/errors.dart#new...
sdk/lib/core/errors.dart:273: int length]) = IndexError;
Yes, fixed in follow-up CL.
Only Dart2js actually caught it.

https://codereview.chromium.org/711003002/diff/1/sdk/lib/core/errors.dart#new...
sdk/lib/core/errors.dart:307: final int invalidValue;
Yes, this is silly. Using implements ArgumentError is probably simpler, or
reusing the invalidValue field if possible.

Powered by Google App Engine
This is Rietveld 408576698