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

Side by Side Diff: tests/compiler/dart2js/source_mapping_test.dart

Issue 1381793002: Revert "dart2js: improve ssa utilization of bool value types" (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 5 years, 2 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) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, 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 import 'dart:async'; 5 import 'dart:async';
6 import 'package:expect/expect.dart'; 6 import 'package:expect/expect.dart';
7 import 'package:async_helper/async_helper.dart'; 7 import 'package:async_helper/async_helper.dart';
8 import 'package:compiler/src/io/code_output.dart'; 8 import 'package:compiler/src/io/code_output.dart';
9 import 'package:compiler/src/io/source_file.dart'; 9 import 'package:compiler/src/io/source_file.dart';
10 import 'package:compiler/src/io/source_information.dart'; 10 import 'package:compiler/src/io/source_information.dart';
(...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after
61 })); 61 }));
62 } 62 }
63 63
64 String FUNCTIONS_TEST = ''' 64 String FUNCTIONS_TEST = '''
65 @void main() { print(test(15)); @} 65 @void main() { print(test(15)); @}
66 // The 'if' has been added to avoid inlining of 'test'. 66 // The 'if' has been added to avoid inlining of 'test'.
67 @int test(int x) { if (x != null) return x; else return null; @}'''; 67 @int test(int x) { if (x != null) return x; else return null; @}''';
68 68
69 String RETURN_TEST = 'void main() { print(((x) { @return x; })(0)); }'; 69 String RETURN_TEST = 'void main() { print(((x) { @return x; })(0)); }';
70 70
71 String NOT_TEST = 'void main() { ((x) { if (@!x) print(x); })(1==2); }'; 71 String NOT_TEST = 'void main() { ((x) { if (@!x) print(x); })(false); }';
72 72
73 String UNARY_TEST = 'void main() { ((x, y) { print(@-x + @~y); })(1,2); }'; 73 String UNARY_TEST = 'void main() { ((x, y) { print(@-x + @~y); })(1,2); }';
74 74
75 String BINARY_TEST = 'void main() { ((x, y) { if (x @!= y) print(x @* y); })(1,2 ); }'; 75 String BINARY_TEST = 'void main() { ((x, y) { if (x @!= y) print(x @* y); })(1,2 ); }';
76 76
77 String SEND_TEST = ''' 77 String SEND_TEST = '''
78 void main() { 78 void main() {
79 @staticSend(0); 79 @staticSend(0);
80 NewSend o = @new NewSend(); 80 NewSend o = @new NewSend();
81 @o.dynamicSend(0); 81 @o.dynamicSend(0);
(...skipping 30 matching lines...) Expand all
112 testSourceMapLocations(FUNCTIONS_TEST); 112 testSourceMapLocations(FUNCTIONS_TEST);
113 testSourceMapLocations(RETURN_TEST); 113 testSourceMapLocations(RETURN_TEST);
114 testSourceMapLocations(NOT_TEST); 114 testSourceMapLocations(NOT_TEST);
115 testSourceMapLocations(UNARY_TEST); 115 testSourceMapLocations(UNARY_TEST);
116 testSourceMapLocations(BINARY_TEST); 116 testSourceMapLocations(BINARY_TEST);
117 testSourceMapLocations(SEND_TEST); 117 testSourceMapLocations(SEND_TEST);
118 testSourceMapLocations(SEND_SET_TEST); 118 testSourceMapLocations(SEND_SET_TEST);
119 testSourceMapLocations(LOOP_TEST); 119 testSourceMapLocations(LOOP_TEST);
120 testSourceMapLocations(INTERCEPTOR_TEST); 120 testSourceMapLocations(INTERCEPTOR_TEST);
121 } 121 }
OLDNEW
« no previous file with comments | « tests/compiler/dart2js/mock_libraries.dart ('k') | tests/compiler/dart2js/type_inference8_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698