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

Unified Diff: tests/compiler/dart2js/code_motion_test.dart

Issue 14416014: After a dynamic call, refine the receiver type by looking at the potential targets of that call. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 7 years, 8 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 side-by-side diff with in-line comments
Download patch
Index: tests/compiler/dart2js/code_motion_test.dart
===================================================================
--- tests/compiler/dart2js/code_motion_test.dart (revision 22031)
+++ tests/compiler/dart2js/code_motion_test.dart (working copy)
@@ -6,13 +6,13 @@
import 'compiler_helper.dart';
const String TEST_ONE = r"""
-foo(int a, int b, bool param2) {
+foo(int a, bool param2) {
for (int i = 0; i < 1; i++) {
var x = a + 5; // '+' is now GVNed.
if (param2) {
- print(a + b);
+ print(a + 42);
} else {
- print(a + b);
+ print(a + 42);
}
}
}
@@ -20,7 +20,7 @@
main() {
String generated = compile(TEST_ONE, entry: 'foo');
- RegExp regexp = new RegExp('a \\+ b');
+ RegExp regexp = new RegExp('a \\+ 42');
Iterator matches = regexp.allMatches(generated).iterator;
Expect.isTrue(matches.moveNext());
Expect.isFalse(matches.moveNext());
« no previous file with comments | « sdk/lib/_internal/compiler/implementation/universe/universe.dart ('k') | tests/compiler/dart2js/dead_bailout_target_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698