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 lib; |
| 6 |
| 7 @MirrorsUsed(targets: "lib") |
5 import 'dart:mirrors'; | 8 import 'dart:mirrors'; |
6 import 'package:expect/expect.dart'; | 9 import 'package:expect/expect.dart'; |
7 | 10 |
8 import 'stringify.dart'; | 11 import 'stringify.dart'; |
9 | 12 |
10 class A<T> { | 13 class A<T> { |
11 var instanceVariable; | 14 var instanceVariable; |
12 get instanceGetter => null; | 15 get instanceGetter => null; |
13 set instanceSetter(x) => x; | 16 set instanceSetter(x) => x; |
14 instanceMethod() => null; | 17 instanceMethod() => null; |
(...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
74 'constructors'); | 77 'constructors'); |
75 | 78 |
76 Expect.setEquals( | 79 Expect.setEquals( |
77 ['TypeVariable(s(T) in s(A), upperBound = Class(s(Object) in ' | 80 ['TypeVariable(s(T) in s(A), upperBound = Class(s(Object) in ' |
78 's(dart.core), top-level))'], | 81 's(dart.core), top-level))'], |
79 cm.declarations.values | 82 cm.declarations.values |
80 .where((dm) => dm is TypeVariableMirror).map(stringify), | 83 .where((dm) => dm is TypeVariableMirror).map(stringify), |
81 'type variables'); | 84 'type variables'); |
82 | 85 |
83 } | 86 } |
OLD | NEW |