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

Side by Side Diff: test/codegen/expect/collection/wrappers.js

Issue 1484263002: Use destructuring assignments for named parameters (#180) (Closed) Base URL: git@github.com:dart-lang/dev_compiler.git@master
Patch Set: Created 5 years 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
OLDNEW
1 dart_library.library('collection/wrappers', null, /* Imports */[ 1 dart_library.library('collection/wrappers', null, /* Imports */[
2 "dart/_runtime", 2 "dart/_runtime",
3 'collection/src/canonicalized_map', 3 'collection/src/canonicalized_map',
4 'dart/core', 4 'dart/core',
5 'dart/math', 5 'dart/math',
6 'dart/collection' 6 'dart/collection'
7 ], /* Lazy imports */[ 7 ], /* Lazy imports */[
8 'collection/src/unmodifiable_wrappers' 8 'collection/src/unmodifiable_wrappers'
9 ], function(exports, dart, canonicalized_map, core, math, collection, unmodifiab le_wrappers) { 9 ], function(exports, dart, canonicalized_map, core, math, collection, unmodifiab le_wrappers) {
10 'use strict'; 10 'use strict';
(...skipping 19 matching lines...) Expand all
30 dart.as(test, dart.functionType(core.bool, [E])); 30 dart.as(test, dart.functionType(core.bool, [E]));
31 return this[_base][dartx.every](test); 31 return this[_base][dartx.every](test);
32 } 32 }
33 expand(f) { 33 expand(f) {
34 dart.as(f, dart.functionType(core.Iterable, [E])); 34 dart.as(f, dart.functionType(core.Iterable, [E]));
35 return this[_base][dartx.expand](f); 35 return this[_base][dartx.expand](f);
36 } 36 }
37 get first() { 37 get first() {
38 return this[_base][dartx.first]; 38 return this[_base][dartx.first];
39 } 39 }
40 firstWhere(test, opts) { 40 firstWhere(test, {orElse = null} = {}) {
41 dart.as(test, dart.functionType(core.bool, [E])); 41 dart.as(test, dart.functionType(core.bool, [E]));
42 let orElse = opts && 'orElse' in opts ? opts.orElse : null;
43 dart.as(orElse, dart.functionType(E, [])); 42 dart.as(orElse, dart.functionType(E, []));
44 return this[_base][dartx.firstWhere](test, {orElse: orElse}); 43 return this[_base][dartx.firstWhere](test, {orElse: orElse});
45 } 44 }
46 fold(initialValue, combine) { 45 fold(initialValue, combine) {
47 dart.as(combine, dart.functionType(dart.dynamic, [dart.dynamic, E])); 46 dart.as(combine, dart.functionType(dart.dynamic, [dart.dynamic, E]));
48 return this[_base][dartx.fold](initialValue, combine); 47 return this[_base][dartx.fold](initialValue, combine);
49 } 48 }
50 forEach(f) { 49 forEach(f) {
51 dart.as(f, dart.functionType(dart.void, [E])); 50 dart.as(f, dart.functionType(dart.void, [E]));
52 return this[_base][dartx.forEach](f); 51 return this[_base][dartx.forEach](f);
(...skipping 11 matching lines...) Expand all
64 return new dart.JsIterator(this.iterator); 63 return new dart.JsIterator(this.iterator);
65 } 64 }
66 join(separator) { 65 join(separator) {
67 if (separator === void 0) 66 if (separator === void 0)
68 separator = ""; 67 separator = "";
69 return this[_base][dartx.join](separator); 68 return this[_base][dartx.join](separator);
70 } 69 }
71 get last() { 70 get last() {
72 return this[_base][dartx.last]; 71 return this[_base][dartx.last];
73 } 72 }
74 lastWhere(test, opts) { 73 lastWhere(test, {orElse = null} = {}) {
75 dart.as(test, dart.functionType(core.bool, [E])); 74 dart.as(test, dart.functionType(core.bool, [E]));
76 let orElse = opts && 'orElse' in opts ? opts.orElse : null;
77 dart.as(orElse, dart.functionType(E, [])); 75 dart.as(orElse, dart.functionType(E, []));
78 return this[_base][dartx.lastWhere](test, {orElse: orElse}); 76 return this[_base][dartx.lastWhere](test, {orElse: orElse});
79 } 77 }
80 get length() { 78 get length() {
81 return this[_base][dartx.length]; 79 return this[_base][dartx.length];
82 } 80 }
83 map(f) { 81 map(f) {
84 dart.as(f, dart.functionType(dart.dynamic, [E])); 82 dart.as(f, dart.functionType(dart.dynamic, [E]));
85 return this[_base][dartx.map](f); 83 return this[_base][dartx.map](f);
86 } 84 }
(...skipping 15 matching lines...) Expand all
102 dart.as(test, dart.functionType(core.bool, [E])); 100 dart.as(test, dart.functionType(core.bool, [E]));
103 return this[_base][dartx.skipWhile](test); 101 return this[_base][dartx.skipWhile](test);
104 } 102 }
105 take(n) { 103 take(n) {
106 return this[_base][dartx.take](n); 104 return this[_base][dartx.take](n);
107 } 105 }
108 takeWhile(test) { 106 takeWhile(test) {
109 dart.as(test, dart.functionType(core.bool, [E])); 107 dart.as(test, dart.functionType(core.bool, [E]));
110 return this[_base][dartx.takeWhile](test); 108 return this[_base][dartx.takeWhile](test);
111 } 109 }
112 toList(opts) { 110 toList({growable = true} = {}) {
113 let growable = opts && 'growable' in opts ? opts.growable : true;
114 return this[_base][dartx.toList]({growable: growable}); 111 return this[_base][dartx.toList]({growable: growable});
115 } 112 }
116 toSet() { 113 toSet() {
117 return this[_base][dartx.toSet](); 114 return this[_base][dartx.toSet]();
118 } 115 }
119 where(test) { 116 where(test) {
120 dart.as(test, dart.functionType(core.bool, [E])); 117 dart.as(test, dart.functionType(core.bool, [E]));
121 return this[_base][dartx.where](test); 118 return this[_base][dartx.where](test);
122 } 119 }
123 toString() { 120 toString() {
(...skipping 692 matching lines...) Expand 10 before | Expand all | Expand 10 after
816 exports.DelegatingSet$ = DelegatingSet$; 813 exports.DelegatingSet$ = DelegatingSet$;
817 exports.DelegatingSet = DelegatingSet; 814 exports.DelegatingSet = DelegatingSet;
818 exports.DelegatingQueue$ = DelegatingQueue$; 815 exports.DelegatingQueue$ = DelegatingQueue$;
819 exports.DelegatingQueue = DelegatingQueue; 816 exports.DelegatingQueue = DelegatingQueue;
820 exports.DelegatingMap$ = DelegatingMap$; 817 exports.DelegatingMap$ = DelegatingMap$;
821 exports.DelegatingMap = DelegatingMap; 818 exports.DelegatingMap = DelegatingMap;
822 exports.MapKeySet$ = MapKeySet$; 819 exports.MapKeySet$ = MapKeySet$;
823 exports.MapValueSet$ = MapValueSet$; 820 exports.MapValueSet$ = MapValueSet$;
824 exports.MapValueSet = MapValueSet; 821 exports.MapValueSet = MapValueSet;
825 }); 822 });
OLDNEW
« no previous file with comments | « test/codegen/expect/collection/src/canonicalized_map.js ('k') | test/codegen/expect/constructors.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698