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

Side by Side Diff: test/dart_codegen/expect/collection/splay_tree.dart

Issue 1160673003: fixes #202, check IndexExpression (Closed) Base URL: git@github.com:dart-lang/dev_compiler.git@master
Patch Set: Created 5 years, 6 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
« no previous file with comments | « test/dart_codegen/expect/collection/linked_hash_map.dart ('k') | tool/sdk_expected_errors.txt » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 part of dart.collection; 1 part of dart.collection;
2 typedef bool _Predicate<T>(T value); 2 typedef bool _Predicate<T>(T value);
3 class _SplayTreeNode<K> {final K key; 3 class _SplayTreeNode<K> {final K key;
4 _SplayTreeNode<K> left; 4 _SplayTreeNode<K> left;
5 _SplayTreeNode<K> right; 5 _SplayTreeNode<K> right;
6 _SplayTreeNode(K this.key); 6 _SplayTreeNode(K this.key);
7 } 7 }
8 class _SplayTreeMapNode<K, V> extends _SplayTreeNode<K> {V value; 8 class _SplayTreeMapNode<K, V> extends _SplayTreeNode<K> {V value;
9 _SplayTreeMapNode(K key, V this.value) : super(key); 9 _SplayTreeMapNode(K key, V this.value) : super(key);
10 } 10 }
(...skipping 133 matching lines...) Expand 10 before | Expand all | Expand 10 after
144 } 144 }
145 } 145 }
146 class SplayTreeMap<K, V> extends _SplayTree<K> implements Map<K, V> {Comparator <K> _comparator; 146 class SplayTreeMap<K, V> extends _SplayTree<K> implements Map<K, V> {Comparator <K> _comparator;
147 _Predicate<Object> _validKey; 147 _Predicate<Object> _validKey;
148 SplayTreeMap([int compare(K key1, K key2), bool isValidKey(Object potentialKey) ]) : _comparator = ((__x12) => DEVC$RT.cast(__x12, dynamic, DEVC$RT.type((Compar ator<K> _) { 148 SplayTreeMap([int compare(K key1, K key2), bool isValidKey(Object potentialKey) ]) : _comparator = ((__x12) => DEVC$RT.cast(__x12, dynamic, DEVC$RT.type((Compar ator<K> _) {
149 } 149 }
150 ), "CompositeCast", """line 265, column 23 of dart:collection/splay_tree.dart: " "", __x12 is Comparator<K>, false))((compare == null) ? Comparable.compare : com pare), _validKey = (isValidKey != null) ? isValidKey : ((v) => v is K); 150 ), "CompositeCast", """line 265, column 23 of dart:collection/splay_tree.dart: " "", __x12 is Comparator<K>, false))((compare == null) ? Comparable.compare : com pare), _validKey = (isValidKey != null) ? isValidKey : ((v) => v is K);
151 factory SplayTreeMap.from(Map other, [int compare(K key1, K key2), bool isValid Key(Object potentialKey)]) { 151 factory SplayTreeMap.from(Map other, [int compare(K key1, K key2), bool isValid Key(Object potentialKey)]) {
152 SplayTreeMap<K, V> result = new SplayTreeMap<K, V>(); 152 SplayTreeMap<K, V> result = new SplayTreeMap<K, V>();
153 other.forEach((k, v) { 153 other.forEach((k, v) {
154 result[k] = DEVC$RT.cast(v, dynamic, V, "CompositeCast", """line 275, column 40 of dart:collection/splay_tree.dart: """, v is V, false); 154 result[DEVC$RT.cast(k, dynamic, K, "CompositeCast", """line 275, column 35 of da rt:collection/splay_tree.dart: """, k is K, false)] = DEVC$RT.cast(v, dynamic, V , "CompositeCast", """line 275, column 40 of dart:collection/splay_tree.dart: "" ", v is V, false);
155 } 155 }
156 ); 156 );
157 return result; 157 return result;
158 } 158 }
159 factory SplayTreeMap.fromIterable(Iterable iterable, { 159 factory SplayTreeMap.fromIterable(Iterable iterable, {
160 K key(element), V value(element), int compare(K key1, K key2), bool isValidKey(O bject potentialKey)} 160 K key(element), V value(element), int compare(K key1, K key2), bool isValidKey(O bject potentialKey)}
161 ) { 161 ) {
162 SplayTreeMap<K, V> map = new SplayTreeMap<K, V>(compare, isValidKey); 162 SplayTreeMap<K, V> map = new SplayTreeMap<K, V>(compare, isValidKey);
163 Maps._fillMapWithMappedIterable(map, iterable, key, value); 163 Maps._fillMapWithMappedIterable(map, iterable, key, value);
164 return map; 164 return map;
(...skipping 366 matching lines...) Expand 10 before | Expand all | Expand 10 after
531 return new _SplayTreeNode<E>(node.key)..left = _copyNode(node.left)..right = _c opyNode(node.right); 531 return new _SplayTreeNode<E>(node.key)..left = _copyNode(node.left)..right = _c opyNode(node.right);
532 } 532 }
533 void clear() { 533 void clear() {
534 _clear(); 534 _clear();
535 } 535 }
536 Set<E> toSet() => _clone(); 536 Set<E> toSet() => _clone();
537 String toString() => IterableBase.iterableToFullString(this, '{', '}'); 537 String toString() => IterableBase.iterableToFullString(this, '{', '}');
538 } 538 }
539 typedef int __CastType14<K>(K __u15, K __u16); 539 typedef int __CastType14<K>(K __u15, K __u16);
540 typedef bool __CastType17(Object __u18); 540 typedef bool __CastType17(Object __u18);
OLDNEW
« no previous file with comments | « test/dart_codegen/expect/collection/linked_hash_map.dart ('k') | tool/sdk_expected_errors.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698