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

Side by Side Diff: pkg/front_end/testcases/inference_new/property_get_toplevel.dart

Issue 2942153002: Enable top level inference of instance property gets/sets. (Closed)
Patch Set: Created 3 years, 6 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) 2017, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2017, 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 /*@testedFeatures=inference*/ 5 /*@testedFeatures=inference*/
6 library test; 6 library test;
7 7
8 class C { 8 class C {
9 int field = 0; 9 int field = 0;
10 int get getter => 0; 10 int get getter => 0;
11 int function() => 0; 11 int function() => 0;
12 } 12 }
13 13
14 C c = new C(); 14 C c = new C();
15 var /*@topType=dynamic*/ field_ref = c. /*@target=C::field*/ field; 15 var /*@topType=int*/ field_ref = c. /*@target=C::field*/ field;
16 var /*@topType=dynamic*/ getter_ref = c. /*@target=C::getter*/ getter; 16 var /*@topType=int*/ getter_ref = c. /*@target=C::getter*/ getter;
17 var /*@topType=() -> int*/ function_ref = c. /*@target=C::function*/ function; 17 var /*@topType=() -> int*/ function_ref = c. /*@target=C::function*/ function;
18 var /*@topType=dynamic*/ field_ref_list = /*@typeArgs=int*/ [ 18 var /*@topType=List<int>*/ field_ref_list = /*@typeArgs=int*/ [
19 c. /*@target=C::field*/ field 19 c. /*@target=C::field*/ field
20 ]; 20 ];
21 var /*@topType=dynamic*/ getter_ref_list = /*@typeArgs=int*/ [ 21 var /*@topType=List<int>*/ getter_ref_list = /*@typeArgs=int*/ [
22 c. /*@target=C::getter*/ getter 22 c. /*@target=C::getter*/ getter
23 ]; 23 ];
24 var /*@topType=List<() -> int>*/ function_ref_list = /*@typeArgs=() -> int*/ [ 24 var /*@topType=List<() -> int>*/ function_ref_list = /*@typeArgs=() -> int*/ [
25 c. /*@target=C::function*/ function 25 c. /*@target=C::function*/ function
26 ]; 26 ];
27 27
28 main() {} 28 main() {}
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698