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

Unified Diff: sdk/lib/_internal/lib/js_mirrors.dart

Issue 217963002: Allow getField of methods. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Address typo-comment. Created 6 years, 9 months 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « sdk/lib/_internal/lib/js_helper.dart ('k') | tests/compiler/dart2js_extra/dart2js_extra.status » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sdk/lib/_internal/lib/js_mirrors.dart
diff --git a/sdk/lib/_internal/lib/js_mirrors.dart b/sdk/lib/_internal/lib/js_mirrors.dart
index cc6787f54811d47087ae07d80bf2db08c00cfc4c..8c5a50bb0aeeb3f733fd1259e50c47391562abe2 100644
--- a/sdk/lib/_internal/lib/js_mirrors.dart
+++ b/sdk/lib/_internal/lib/js_mirrors.dart
@@ -386,10 +386,13 @@ class JsLibraryMirror extends JsDeclarationMirror with JsObjectMirror
String name = _functions[i];
var jsFunction = JS('', '#[#]', _globalObject, name);
String unmangledName = mangledGlobalNames[name];
- if (unmangledName == null) {
+ if (unmangledName == null ||
+ JS('bool', "!!#['getterStub']", jsFunction)) {
// If there is no unmangledName, [jsFunction] is either a synthetic
// implementation detail, or something that is excluded
// by @MirrorsUsed.
+ // If it has a getterStub property it is a synthetic stub.
+ // TODO(floitsch): Remove the getterStub hack.
continue;
}
bool isConstructor = unmangledName.startsWith('new ');
« no previous file with comments | « sdk/lib/_internal/lib/js_helper.dart ('k') | tests/compiler/dart2js_extra/dart2js_extra.status » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698