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

Side by Side Diff: tests/corelib/hash_set_test.dart

Issue 915323002: Compact LinkedHashMap/Set implementation. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 5 years, 10 months 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 //
5 // VMOptions=
6 // VMOptions=--use_compact_hash
4 7
5 // Tests of hash set behavior, with focus in iteration and concurrent 8 // Tests of hash set behavior, with focus in iteration and concurrent
6 // modification errors. 9 // modification errors.
7 10
8 library hash_map2_test; 11 library hash_map2_test;
9 import "package:expect/expect.dart"; 12 import "package:expect/expect.dart";
10 import 'dart:collection'; 13 import 'dart:collection';
11 14
12 testSet(Set newSet(), Set newSetFrom(Iterable from)) { 15 testSet(Set newSet(), Set newSetFrom(Iterable from)) {
13 16
(...skipping 308 matching lines...) Expand 10 before | Expand all | Expand 10 after
322 // Can't make a bad compareTo that isn't invalid. 325 // Can't make a bad compareTo that isn't invalid.
323 int compareTo(BadHashCode other) => id - other.id; 326 int compareTo(BadHashCode other) => id - other.id;
324 } 327 }
325 328
326 class Mutable { 329 class Mutable {
327 int id; 330 int id;
328 Mutable(this.id); 331 Mutable(this.id);
329 int get hashCode => id; 332 int get hashCode => id;
330 bool operator==(other) => other is Mutable && id == other.id; 333 bool operator==(other) => other is Mutable && id == other.id;
331 } 334 }
OLDNEW
« runtime/lib/compact_hash.dart ('K') | « tests/corelib/hash_map_test.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698