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

Unified Diff: pkg/front_end/testcases/inference/list_literals_top_level.dart

Issue 2874033003: Set MethodInvocation.interfaceTarget during type inference. (Closed)
Patch Set: Created 3 years, 7 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: pkg/front_end/testcases/inference/list_literals_top_level.dart
diff --git a/pkg/front_end/testcases/inference/list_literals_top_level.dart b/pkg/front_end/testcases/inference/list_literals_top_level.dart
index 58c36650730d5c1b19e81b940b3e810408387aec..e89e38c0901ad99bfbdf197542bda5a4d0460aac 100644
--- a/pkg/front_end/testcases/inference/list_literals_top_level.dart
+++ b/pkg/front_end/testcases/inference/list_literals_top_level.dart
@@ -7,16 +7,16 @@ library test;
var /*@topType=List<int>*/ x1 = /*@typeArgs=int*/ [1, 2, 3];
test1() {
- x1.add(/*error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ 'hi');
- x1.add(/*error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ 4.0);
- x1.add(4);
+ x1. /*@target=List::add*/ add(/*error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ 'hi');
+ x1. /*@target=List::add*/ add(/*error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ 4.0);
+ x1. /*@target=List::add*/ add(4);
List<num> y = x1;
}
var /*@topType=List<num>*/ x2 = /*@typeArgs=num*/ [1, 2.0, 3];
test2() {
- x2.add(/*error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ 'hi');
- x2.add(4.0);
+ x2. /*@target=List::add*/ add(/*error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ 'hi');
+ x2. /*@target=List::add*/ add(4.0);
List<int> y = /*info:ASSIGNMENT_CAST*/ x2;
}

Powered by Google App Engine
This is Rietveld 408576698