| OLD | NEW |
| 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2013, 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 library test.synthetic_accessor_properties; | 5 library test.synthetic_accessor_properties; |
| 6 | 6 |
| 7 @MirrorsUsed(targets: "test.synthetic_accessor_properties") |
| 7 import 'dart:mirrors'; | 8 import 'dart:mirrors'; |
| 8 import 'package:expect/expect.dart'; | 9 import 'package:expect/expect.dart'; |
| 9 | 10 |
| 10 import 'stringify.dart'; | 11 import 'stringify.dart'; |
| 11 | 12 |
| 12 class C { | 13 class C { |
| 13 String instanceField; | 14 String instanceField; |
| 14 final num finalInstanceField = 2; | 15 final num finalInstanceField = 2; |
| 15 | 16 |
| 16 static bool staticField; | 17 static bool staticField; |
| (...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 61 ' type = Class(s(bool) in s(dart.core), top-level))', pm); | 62 ' type = Class(s(bool) in s(dart.core), top-level))', pm); |
| 62 | 63 |
| 63 mm = cm.staticMembers[#finalStaticField]; | 64 mm = cm.staticMembers[#finalStaticField]; |
| 64 expect('Method(s(finalStaticField) in s(C), synthetic, static, getter)', mm); | 65 expect('Method(s(finalStaticField) in s(C), synthetic, static, getter)', mm); |
| 65 Expect.equals(reflectClass(int), mm.returnType); | 66 Expect.equals(reflectClass(int), mm.returnType); |
| 66 Expect.listEquals([], mm.parameters); | 67 Expect.listEquals([], mm.parameters); |
| 67 | 68 |
| 68 mm = cm.staticMembers[const Symbol('finalStaticField=')]; | 69 mm = cm.staticMembers[const Symbol('finalStaticField=')]; |
| 69 Expect.isNull(mm); | 70 Expect.isNull(mm); |
| 70 } | 71 } |
| OLD | NEW |