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

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

Issue 2919623002: Implement type inference for PropertySet. (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/property_set_bad_setter.dart
diff --git a/pkg/front_end/testcases/inference/inferred_type_cascade.dart b/pkg/front_end/testcases/inference/property_set_bad_setter.dart
similarity index 65%
copy from pkg/front_end/testcases/inference/inferred_type_cascade.dart
copy to pkg/front_end/testcases/inference/property_set_bad_setter.dart
index 088866313a94fa0f3ba63a7cb92fdd63beb29de8..11863b823c47ec61cc3c276c8f1b53835e4217fd 100644
--- a/pkg/front_end/testcases/inference/inferred_type_cascade.dart
+++ b/pkg/front_end/testcases/inference/property_set_bad_setter.dart
@@ -6,12 +6,11 @@
library test;
class A {
- int a;
- List<int> b;
- void m() {}
+ void set x() {}
}
-var /*@topType=A*/ v = new A()
- ..a = 1
- .. /*@target=A::b*/ b. /*@target=List::add*/ add(2)
- ..m();
+void f(A a) {
+ var /*@type=int*/ x = a. /*@target=A::x*/ x = 0;
+}
+
+main() {}

Powered by Google App Engine
This is Rietveld 408576698