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

Side by Side Diff: sdk/lib/_internal/js_runtime/lib/collection_patch.dart

Issue 2825793002: js_runtime: LinkedHashMap._makeEmpty may be removed (Closed)
Patch Set: Created 3 years, 8 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 | « no previous file | no next file » | 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 // Patch file for dart:collection classes. 5 // Patch file for dart:collection classes.
6 import 'dart:_foreign_helper' show JS; 6 import 'dart:_foreign_helper' show JS;
7 import 'dart:_js_helper' 7 import 'dart:_js_helper'
8 show 8 show
9 fillLiteralMap, 9 fillLiteralMap,
10 InternalMap, 10 InternalMap,
(...skipping 528 matching lines...) Expand 10 before | Expand all | Expand 10 after
539 // Private factory constructor called by generated code for map literals. 539 // Private factory constructor called by generated code for map literals.
540 @NoThrows() 540 @NoThrows()
541 @NoInline() 541 @NoInline()
542 @NoSideEffects() 542 @NoSideEffects()
543 factory LinkedHashMap._empty() { 543 factory LinkedHashMap._empty() {
544 return new JsLinkedHashMap<K, V>.es6(); 544 return new JsLinkedHashMap<K, V>.es6();
545 } 545 }
546 546
547 // Private factory static function called by generated code for map literals. 547 // Private factory static function called by generated code for map literals.
548 // This version is for map literals without type parameters. 548 // This version is for map literals without type parameters.
549 @NoThrows()
549 @NoInline() 550 @NoInline()
551 @NoSideEffects()
550 static _makeEmpty() => new JsLinkedHashMap(); 552 static _makeEmpty() => new JsLinkedHashMap();
551 553
552 // Private factory static function called by generated code for map literals. 554 // Private factory static function called by generated code for map literals.
553 // This version is for map literals without type parameters. 555 // This version is for map literals without type parameters.
554 @NoInline() 556 @NoInline()
555 static _makeLiteral(keyValuePairs) => 557 static _makeLiteral(keyValuePairs) =>
556 fillLiteralMap(keyValuePairs, new JsLinkedHashMap()); 558 fillLiteralMap(keyValuePairs, new JsLinkedHashMap());
557 } 559 }
558 560
559 class _LinkedIdentityHashMap<K, V> extends JsLinkedHashMap<K, V> { 561 class _LinkedIdentityHashMap<K, V> extends JsLinkedHashMap<K, V> {
(...skipping 1098 matching lines...) Expand 10 before | Expand all | Expand 10 after
1658 } else if (_cell == null) { 1660 } else if (_cell == null) {
1659 _current = null; 1661 _current = null;
1660 return false; 1662 return false;
1661 } else { 1663 } else {
1662 _current = _cell._element; 1664 _current = _cell._element;
1663 _cell = _cell._next; 1665 _cell = _cell._next;
1664 return true; 1666 return true;
1665 } 1667 }
1666 } 1668 }
1667 } 1669 }
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698