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

Side by Side Diff: runtime/lib/mirrors_patch.dart

Issue 45293002: Mirror API removals: async invocations, mirrorSystemOf(port), Mirror.mirrors. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: rebase Created 7 years, 1 month 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 | Annotate | Revision Log
« no previous file with comments | « no previous file | runtime/tests/vm/vm.status » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 import "dart:nativewrappers"; 5 import "dart:nativewrappers";
6 // TODO(ahe): Move _symbol_dev.Symbol to its own "private" library? 6 // TODO(ahe): Move _symbol_dev.Symbol to its own "private" library?
7 import "dart:_collection-dev" as _symbol_dev; 7 import "dart:_collection-dev" as _symbol_dev;
8 8
9 /** 9 /**
10 * Returns a [MirrorSystem] for the current isolate. 10 * Returns a [MirrorSystem] for the current isolate.
11 */ 11 */
12 patch MirrorSystem currentMirrorSystem() { 12 patch MirrorSystem currentMirrorSystem() {
13 return _Mirrors.currentMirrorSystem(); 13 return _Mirrors.currentMirrorSystem();
14 } 14 }
15 15
16 /** 16 /**
17 * Creates a [MirrorSystem] for the isolate which is listening on 17 * Creates a [MirrorSystem] for the isolate which is listening on
18 * the [SendPort]. 18 * the [SendPort].
19 */ 19 */
20 patch Future<MirrorSystem> mirrorSystemOf(SendPort port) { 20 Future<MirrorSystem> mirrorSystemOf(SendPort port) {
21 return _Mirrors.mirrorSystemOf(port); 21 return _Mirrors.mirrorSystemOf(port);
22 } 22 }
23 23
24 /** 24 /**
25 * Returns an [InstanceMirror] for some Dart language object. 25 * Returns an [InstanceMirror] for some Dart language object.
26 * 26 *
27 * This only works if this mirror system is associated with the 27 * This only works if this mirror system is associated with the
28 * current running isolate. 28 * current running isolate.
29 */ 29 */
30 patch InstanceMirror reflect(Object reflectee) { 30 patch InstanceMirror reflect(Object reflectee) {
(...skipping 27 matching lines...) Expand all
58 } 58 }
59 if (library != null) name = _mangleName(name, library._reflectee); 59 if (library != null) name = _mangleName(name, library._reflectee);
60 return new _symbol_dev.Symbol.unvalidated(name); 60 return new _symbol_dev.Symbol.unvalidated(name);
61 } 61 }
62 62
63 static _unmangleName(String name) 63 static _unmangleName(String name)
64 native "Mirrors_unmangleName"; 64 native "Mirrors_unmangleName";
65 static _mangleName(String name, _MirrorReference lib) 65 static _mangleName(String name, _MirrorReference lib)
66 native "Mirrors_mangleName"; 66 native "Mirrors_mangleName";
67 } 67 }
OLDNEW
« no previous file with comments | « no previous file | runtime/tests/vm/vm.status » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698