OLD | NEW |
1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2012, 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 // VM-specific implementation of the dart:mirrors library. | 5 // VM-specific implementation of the dart:mirrors library. |
6 | 6 |
7 import "dart:collection" show UnmodifiableListView, UnmodifiableMapView; | |
8 import "dart:async" show Future; | |
9 | |
10 var dirty = false; | 7 var dirty = false; |
11 final emptyList = new UnmodifiableListView([]); | 8 final emptyList = new UnmodifiableListView([]); |
12 final emptyMap = new UnmodifiableMapView({}); | 9 final emptyMap = new UnmodifiableMapView({}); |
13 | 10 |
14 class _InternalMirrorError { | 11 class _InternalMirrorError { |
15 final String _msg; | 12 final String _msg; |
16 const _InternalMirrorError(String this._msg); | 13 const _InternalMirrorError(String this._msg); |
17 String toString() => _msg; | 14 String toString() => _msg; |
18 } | 15 } |
19 | 16 |
(...skipping 1650 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1670 if (typeMirror == null) { | 1667 if (typeMirror == null) { |
1671 typeMirror = makeLocalTypeMirror(key); | 1668 typeMirror = makeLocalTypeMirror(key); |
1672 _instantiationCache[key] = typeMirror; | 1669 _instantiationCache[key] = typeMirror; |
1673 if (typeMirror is ClassMirror && !typeMirror._isGeneric) { | 1670 if (typeMirror is ClassMirror && !typeMirror._isGeneric) { |
1674 _declarationCache[key] = typeMirror; | 1671 _declarationCache[key] = typeMirror; |
1675 } | 1672 } |
1676 } | 1673 } |
1677 return typeMirror; | 1674 return typeMirror; |
1678 } | 1675 } |
1679 } | 1676 } |
OLD | NEW |