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

Issue 16285004: Better documentation on Sets and Maps, and more. (Closed)

Created:
7 years, 6 months ago by Lasse Reichstein Nielsen
Modified:
7 years, 6 months ago
Reviewers:
regis, floitsch, ngeoffray
CC:
reviews_dartlang.org
Visibility:
Public.

Description

Patch Set 1 #

Patch Set 2 : Updated documentation of list.asMap #

Patch Set 3 : Added documentation for String.contains. #

Patch Set 4 : Change to runtime string patch - always check index of contains method. #

Total comments: 9

Patch Set 5 : Improve documentation on num methods. #

Patch Set 6 : Address review comments. #

Total comments: 4

Patch Set 7 : A few more documentation tweaks #

Total comments: 2

Patch Set 8 : Address comments. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+125 lines, -30 lines) Patch
M runtime/lib/string_patch.dart View 1 2 3 1 chunk +4 lines, -1 line 0 comments Download
M sdk/lib/_internal/compiler/implementation/lib/string_helper.dart View 1 2 1 chunk +1 line, -1 line 0 comments Download
M sdk/lib/async/stream.dart View 1 1 chunk +1 line, -1 line 0 comments Download
M sdk/lib/collection/hash_map.dart View 1 2 3 4 5 6 7 1 chunk +11 lines, -0 lines 0 comments Download
M sdk/lib/collection/hash_set.dart View 1 2 3 4 5 3 chunks +15 lines, -2 lines 0 comments Download
M sdk/lib/collection/linked_hash_map.dart View 1 2 3 4 5 2 chunks +14 lines, -1 line 0 comments Download
M sdk/lib/collection/linked_hash_set.dart View 1 2 3 4 5 3 chunks +20 lines, -0 lines 0 comments Download
M sdk/lib/core/list.dart View 1 1 chunk +2 lines, -1 line 0 comments Download
M sdk/lib/core/num.dart View 1 2 3 4 5 6 7 5 chunks +10 lines, -12 lines 0 comments Download
M sdk/lib/core/set.dart View 1 2 3 4 5 4 chunks +40 lines, -8 lines 0 comments Download
M sdk/lib/core/string.dart View 1 2 1 chunk +7 lines, -3 lines 0 comments Download

Messages

Total messages: 7 (0 generated)
Lasse Reichstein Nielsen
7 years, 6 months ago (2013-06-03 12:15:31 UTC) #1
Lasse Reichstein Nielsen
Adding VM/dart2js people because I touch their libraries.
7 years, 6 months ago (2013-06-04 11:44:28 UTC) #2
ngeoffray
LGTM https://codereview.chromium.org/16285004/diff/8001/sdk/lib/collection/hash_map.dart File sdk/lib/collection/hash_map.dart (right): https://codereview.chromium.org/16285004/diff/8001/sdk/lib/collection/hash_map.dart#newcode13 sdk/lib/collection/hash_map.dart:13: * anti-symmetric, trasitive, and consistent over time), and ...
7 years, 6 months ago (2013-06-04 11:51:33 UTC) #3
Lasse Reichstein Nielsen
All typos fixed. Thanks!
7 years, 6 months ago (2013-06-04 14:14:06 UTC) #4
floitsch
LGTM. https://codereview.chromium.org/16285004/diff/5004/sdk/lib/collection/hash_map.dart File sdk/lib/collection/hash_map.dart (right): https://codereview.chromium.org/16285004/diff/5004/sdk/lib/collection/hash_map.dart#newcode13 sdk/lib/collection/hash_map.dart:13: * anti-symmetric, trasnitive, and consistent over time), and ...
7 years, 6 months ago (2013-06-06 14:00:52 UTC) #5
Lasse Reichstein Nielsen
Committed patchset #8 manually as r23734 (presubmit successful).
7 years, 6 months ago (2013-06-07 08:51:49 UTC) #6
Lasse Reichstein Nielsen
7 years, 6 months ago (2013-06-10 05:48:50 UTC) #7
Message was sent while issue was closed.
https://codereview.chromium.org/16285004/diff/5004/sdk/lib/collection/hash_ma...
File sdk/lib/collection/hash_map.dart (right):

https://codereview.chromium.org/16285004/diff/5004/sdk/lib/collection/hash_ma...
sdk/lib/collection/hash_map.dart:13: * anti-symmetric, trasnitive, and
consistent over time), and that `hashCode`
But I changed that! Really!
Grumble!

https://codereview.chromium.org/16285004/diff/5004/sdk/lib/collection/hash_ma...
sdk/lib/collection/hash_map.dart:16: * The map allows `null` as a key.
That is a property of doubles, which should be noted on the double type:
"doesn't play well with hash maps".

https://codereview.chromium.org/16285004/diff/16001/sdk/lib/core/num.dart
File sdk/lib/core/num.dart (right):

https://codereview.chromium.org/16285004/diff/16001/sdk/lib/core/num.dart#new...
sdk/lib/core/num.dart:168: * Converts [this] as a [double] to a string
representation with
On 2013/06/06 14:00:53, floitsch wrote:
> "Converts `this` to a [double] and then applies `toStringAsFixed` on the
> result." ?

Done.

> Should we just say that this is equivalent to:
> this.toDouble().toStringAsFixed().

That would seem like a recursive definition, since double is a num.
I know that double has its own version, but that means that this description
really only applies to int - which is weird, so I try to write this so it
applies to both int and double.

> See [double.toStringAsFixed].
> 
> ?

Powered by Google App Engine
This is Rietveld 408576698