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: tests/compiler/dart2js/kernel/impact_test.dart

Issue 2359453002: Handle local functions in kernel_impact. (Closed)
Patch Set: Created 4 years, 3 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
OLDNEW
1 // Copyright (c) 2016, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2016, 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 dart2js.kernel.impact_test; 5 library dart2js.kernel.impact_test;
6 6
7 import 'dart:async'; 7 import 'dart:async';
8 import 'package:async_helper/async_helper.dart'; 8 import 'package:async_helper/async_helper.dart';
9 import 'package:compiler/src/commandline_options.dart'; 9 import 'package:compiler/src/commandline_options.dart';
10 import 'package:compiler/src/common.dart'; 10 import 'package:compiler/src/common.dart';
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after
56 testIfThen(); 56 testIfThen();
57 testIfThenElse(); 57 testIfThenElse();
58 testTopLevelInvoke(); 58 testTopLevelInvoke();
59 testTopLevelInvokeTyped(); 59 testTopLevelInvokeTyped();
60 testTopLevelField(); 60 testTopLevelField();
61 testTopLevelFieldTyped(); 61 testTopLevelFieldTyped();
62 testDynamicInvoke(null); 62 testDynamicInvoke(null);
63 testDynamicGet(null); 63 testDynamicGet(null);
64 testDynamicSet(null); 64 testDynamicSet(null);
65 testLocalWithInitializer(); 65 testLocalWithInitializer();
66 testLocalFunction();
67 testLocalFunctionInvoke();
68 testLocalFunctionGet();
66 testInvokeIndex(null); 69 testInvokeIndex(null);
67 testInvokeIndexSet(null); 70 testInvokeIndexSet(null);
68 testAssert(); 71 testAssert();
69 testAssertWithMessage(); 72 testAssertWithMessage();
70 testFactoryInvoke(); 73 testFactoryInvoke();
71 testFactoryInvokeGeneric(); 74 testFactoryInvokeGeneric();
72 testFactoryInvokeGenericRaw(); 75 testFactoryInvokeGenericRaw();
73 testFactoryInvokeGenericDynamic(); 76 testFactoryInvokeGenericDynamic();
74 } 77 }
75 78
(...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after
157 o.f6(8, b: 9); 160 o.f6(8, b: 9);
158 o.f7(10, c: 11); 161 o.f7(10, c: 11);
159 o.f8(12, b: 13, c: 14); 162 o.f8(12, b: 13, c: 14);
160 o.f9(15, c: 16, b: 17); 163 o.f9(15, c: 16, b: 17);
161 } 164 }
162 testDynamicGet(o) => o.foo; 165 testDynamicGet(o) => o.foo;
163 testDynamicSet(o) => o.foo = 42; 166 testDynamicSet(o) => o.foo = 42;
164 testLocalWithInitializer() { 167 testLocalWithInitializer() {
165 var l = 42; 168 var l = 42;
166 } 169 }
170 testLocalFunction() {
171 localFunction() {}
172 }
173 testLocalFunctionInvoke() {
174 localFunction() {}
175 localFunction();
176 }
177 testLocalFunctionGet() {
178 localFunction() {}
179 localFunction;
180 }
167 testInvokeIndex(o) => o[42]; 181 testInvokeIndex(o) => o[42];
168 testInvokeIndexSet(o) => o[42] = null; 182 testInvokeIndexSet(o) => o[42] = null;
169 testAssert() { 183 testAssert() {
170 assert(true); 184 assert(true);
171 } 185 }
172 testAssertWithMessage() { 186 testAssertWithMessage() {
173 assert(true, 'ok'); 187 assert(true, 'ok');
174 } 188 }
175 testFactoryInvoke() { 189 testFactoryInvoke() {
176 new Class.fact(); 190 new Class.fact();
(...skipping 75 matching lines...) Expand 10 before | Expand all | Expand 10 after
252 // we cannot tell the diferrence. 266 // we cannot tell the diferrence.
253 builder.registerFeature(Feature.STRING_INTERPOLATION); 267 builder.registerFeature(Feature.STRING_INTERPOLATION);
254 builder.registerFeature(Feature.STRING_JUXTAPOSITION); 268 builder.registerFeature(Feature.STRING_JUXTAPOSITION);
255 break; 269 break;
256 default: 270 default:
257 } 271 }
258 } 272 }
259 impact.nativeData.forEach(builder.registerNativeData); 273 impact.nativeData.forEach(builder.registerNativeData);
260 return builder; 274 return builder;
261 } 275 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698