| 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 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. |
| (...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 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 } |
| 68 |
| 69 // TODO(rmacnak): Eliminate this class. |
| 70 class MirroredCompilationError { |
| 71 final String message; |
| 72 |
| 73 MirroredCompilationError(this.message); |
| 74 |
| 75 String toString() { |
| 76 return "Compile-time error during mirrored execution: <$message>"; |
| 77 } |
| 78 } |
| OLD | NEW |