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

Side by Side Diff: dart/tests/try/web/incremental_compilation_update_test.dart

Issue 760383003: Incremental compilation of constants. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge
Patch Set: Merged with r42279 and CL 760383003. Created 6 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2014, 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 trydart.incremental_compilation_update_test; 5 library trydart.incremental_compilation_update_test;
6 6
7 import 'dart:html' hide 7 import 'dart:html' hide
8 Element; 8 Element;
9 9
10 import 'dart:async' show 10 import 'dart:async' show
(...skipping 1274 matching lines...) Expand 10 before | Expand all | Expand 10 after
1285 } 1285 }
1286 """, 1286 """,
1287 const <String>['v2']), 1287 const <String>['v2']),
1288 ], 1288 ],
1289 1289
1290 // Test that interceptor classes are handled correctly. 1290 // Test that interceptor classes are handled correctly.
1291 const <ProgramResult>[ 1291 const <ProgramResult>[
1292 const ProgramResult( 1292 const ProgramResult(
1293 r""" 1293 r"""
1294 main() { 1294 main() {
1295 // TODO(ahe): Remove next line when new constants are handled correctly.
1296 [].map(null);
1297 print('v1'); 1295 print('v1');
1298 } 1296 }
1299 """, 1297 """,
1300 const <String>['v1']), 1298 const <String>['v1']),
1301 const ProgramResult( 1299 const ProgramResult(
1302 r""" 1300 r"""
1303 main() { 1301 main() {
1304 ['v2'].forEach(print); 1302 ['v2'].forEach(print);
1305 } 1303 }
1306 """, 1304 """,
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after
1364 1362
1365 class B extends A { 1363 class B extends A {
1366 } 1364 }
1367 1365
1368 main() { 1366 main() {
1369 new A().bar(); 1367 new A().bar();
1370 } 1368 }
1371 """, 1369 """,
1372 const <String>['Called bar']), 1370 const <String>['Called bar']),
1373 ], 1371 ],
1372
1373 // Test that constants are handled correctly.
1374 const <ProgramResult>[
1375 const ProgramResult(
1376 r"""
1377 class C {
1378 final String value;
1379 const C(this.value);
1380 }
1381
1382 main() {
1383 print(const C('v1').value);
1384 }
1385 """,
1386 const <String>['v1']),
1387 const ProgramResult(
1388 r"""
1389 class C {
1390 final String value;
1391 const C(this.value);
1392 }
1393
1394 main() {
1395 print(const C('v2').value);
1396 }
1397 """,
1398 const <String>['v2']),
1399 ],
1374 ]; 1400 ];
1375 1401
1376 void main() { 1402 void main() {
1377 listener.start(); 1403 listener.start();
1378 1404
1379 document.head.append(lineNumberStyle()); 1405 document.head.append(lineNumberStyle());
1380 1406
1381 summary = new SpanElement(); 1407 summary = new SpanElement();
1382 document.body.append(new HeadingElement.h1() 1408 document.body.append(new HeadingElement.h1()
1383 ..appendText("Incremental compiler tests") 1409 ..appendText("Incremental compiler tests")
(...skipping 180 matching lines...) Expand 10 before | Expand all | Expand 10 after
1564 position: absolute; 1590 position: absolute;
1565 left: 0px; 1591 left: 0px;
1566 width: 3em; 1592 width: 3em;
1567 text-align: right; 1593 text-align: right;
1568 background-color: lightgoldenrodyellow; 1594 background-color: lightgoldenrodyellow;
1569 } 1595 }
1570 '''); 1596 ''');
1571 style.type = 'text/css'; 1597 style.type = 'text/css';
1572 return style; 1598 return style;
1573 } 1599 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698