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

Side by Side Diff: test/dart_codegen/expect/core/list.dart

Issue 961493003: don't run dart gen on JS patch code (Closed) Base URL: git@github.com:dart-lang/dev_compiler.git@master
Patch Set: Created 5 years, 9 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/core/iterable.dart ('k') | test/dart_codegen/expect/core/object.dart » ('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.core; 1 part of dart.core;
2 2
3 abstract class List<E> implements Iterable<E>, EfficientLength { 3 abstract class List<E> implements Iterable<E>, EfficientLength {
4 factory List([int length = const _ListConstructorSentinel()]) { 4 external factory List([int length]);
5 if (length == const _ListConstructorSentinel()) { 5 external factory List.filled(int length, E fill);
6 return ((__x26) => DDC$RT.cast(__x26, dynamic, 6 external factory List.from(Iterable elements, {bool growable: true});
7 DDC$RT.type((List<E> _) {}), "CastExact",
8 """line 79, column 14 of dart:core/list.dart: """, __x26 is List<E>,
9 false))(new JSArray<E>.emptyGrowable());
10 }
11 return ((__x27) => DDC$RT.cast(__x27, dynamic, DDC$RT.type((List<E> _) {}),
12 "CastExact", """line 81, column 12 of dart:core/list.dart: """,
13 __x27 is List<E>, false))(new JSArray<E>.fixed(length));
14 }
15 factory List.filled(int length, E fill) {
16 List result = ((__x28) => DDC$RT.cast(__x28, dynamic,
17 DDC$RT.type((List<dynamic> _) {}), "CastExact",
18 """line 93, column 19 of dart:core/list.dart: """,
19 __x28 is List<dynamic>, true))(new JSArray<E>.fixed(length));
20 if (length != 0 && fill != null) {
21 for (int i = 0; i < result.length; i++) {
22 result[i] = fill;
23 }
24 }
25 return DDC$RT.cast(result, DDC$RT.type((List<dynamic> _) {}),
26 DDC$RT.type((List<E> _) {}), "CastDynamic",
27 """line 99, column 12 of dart:core/list.dart: """, result is List<E>,
28 false);
29 }
30 factory List.from(Iterable elements, {bool growable: true}) {
31 List<E> list = new List<E>();
32 for (E e in elements) {
33 list.add(e);
34 }
35 if (growable) return list;
36 return ((__x29) => DDC$RT.cast(__x29, DDC$RT.type((List<dynamic> _) {}),
37 DDC$RT.type((List<E> _) {}), "CastDynamic",
38 """line 116, column 12 of dart:core/list.dart: """, __x29 is List<E>,
39 false))(makeListFixedLength(list));
40 }
41 factory List.generate(int length, E generator(int index), 7 factory List.generate(int length, E generator(int index),
42 {bool growable: true}) { 8 {bool growable: true}) {
43 List<E> result; 9 List<E> result;
44 if (growable) { 10 if (growable) {
45 result = <E>[]..length = length; 11 result = <E>[]..length = length;
46 } else { 12 } else {
47 result = new List<E>(length); 13 result = new List<E>(length);
48 } 14 }
49 for (int i = 0; i < length; i++) { 15 for (int i = 0; i < length; i++) {
50 result[i] = generator(i); 16 result[i] = generator(i);
(...skipping 21 matching lines...) Expand all
72 void removeWhere(bool test(E element)); 38 void removeWhere(bool test(E element));
73 void retainWhere(bool test(E element)); 39 void retainWhere(bool test(E element));
74 List<E> sublist(int start, [int end]); 40 List<E> sublist(int start, [int end]);
75 Iterable<E> getRange(int start, int end); 41 Iterable<E> getRange(int start, int end);
76 void setRange(int start, int end, Iterable<E> iterable, [int skipCount = 0]); 42 void setRange(int start, int end, Iterable<E> iterable, [int skipCount = 0]);
77 void removeRange(int start, int end); 43 void removeRange(int start, int end);
78 void fillRange(int start, int end, [E fillValue]); 44 void fillRange(int start, int end, [E fillValue]);
79 void replaceRange(int start, int end, Iterable<E> replacement); 45 void replaceRange(int start, int end, Iterable<E> replacement);
80 Map<int, E> asMap(); 46 Map<int, E> asMap();
81 } 47 }
OLDNEW
« no previous file with comments | « test/dart_codegen/expect/core/iterable.dart ('k') | test/dart_codegen/expect/core/object.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698