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

Side by Side Diff: lib/src/utils_observe.dart

Issue 50433010: WebUI fixes for SDK 0.8.10 (Closed) Base URL: git@github.com:dart-lang/web-ui.git@master
Patch Set: Created 7 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 unified diff | Download patch
« no previous file with comments | « lib/src/html5_setters.g.dart ('k') | pubspec.yaml » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 4
5 library web_ui.src.utils_observe; 5 library web_ui.src.utils_observe;
6 6
7 import 'dart:collection';
8
9 // TODO(jmesserly): helpers to combine hash codes. Reuse these from somewhere. 7 // TODO(jmesserly): helpers to combine hash codes. Reuse these from somewhere.
10 hash2(x, y) => x.hashCode * 31 + y.hashCode; 8 hash2(x, y) => x.hashCode * 31 + y.hashCode;
11 9
12 hash3(x, y, z) => hash2(hash2(x, y), z); 10 hash3(x, y, z) => hash2(hash2(x, y), z);
13 11
14 hash4(w, x, y, z) => hash2(hash2(w, x), hash2(y, z)); 12 hash4(w, x, y, z) => hash2(hash2(w, x), hash2(y, z));
15 13
16 class Arrays { 14 class Arrays {
17 static void copy(List src, int srcStart, 15 static void copy(List src, int srcStart,
18 List dst, int dstStart, int count) { 16 List dst, int dstStart, int count) {
(...skipping 19 matching lines...) Expand all
38 if (start < 0 ) { 36 if (start < 0 ) {
39 String message = "$start must be greater than or equal to 0"; 37 String message = "$start must be greater than or equal to 0";
40 throw new RangeError(message); 38 throw new RangeError(message);
41 } 39 }
42 if (start + length > a.length) { 40 if (start + length > a.length) {
43 String message = "$start + $length must be in the range [0..${a.length})"; 41 String message = "$start + $length must be in the range [0..${a.length})";
44 throw new RangeError(message); 42 throw new RangeError(message);
45 } 43 }
46 } 44 }
47 } 45 }
48
49 // TODO(jmesserly): bogus type to workaround spurious VM bug with generic base
50 // class and mixins.
51 abstract class IterableWorkaround extends IterableBase<dynamic> {}
52 abstract class ListMixinWorkaround extends ListMixin<dynamic> {}
OLDNEW
« no previous file with comments | « lib/src/html5_setters.g.dart ('k') | pubspec.yaml » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698