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

Unified Diff: dart/sdk/lib/_internal/compiler/implementation/lib/js_helper.dart

Issue 16154021: Implement reflecting on uninstantiated classes. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge
Patch Set: Update comment in second test. Created 7 years, 6 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
Index: dart/sdk/lib/_internal/compiler/implementation/lib/js_helper.dart
diff --git a/dart/sdk/lib/_internal/compiler/implementation/lib/js_helper.dart b/dart/sdk/lib/_internal/compiler/implementation/lib/js_helper.dart
index ab36275286da195ec31e8e5a5ba009c5dc01cc14..dfa503dd53f4e55d152235ea48af3804e23c870d 100644
--- a/dart/sdk/lib/_internal/compiler/implementation/lib/js_helper.dart
+++ b/dart/sdk/lib/_internal/compiler/implementation/lib/js_helper.dart
@@ -570,11 +570,11 @@ class Primitives {
// TODO(ahe): Generalize this and improve test coverage of
// reflecting on intercepted classes.
if (JS('bool', '# == "String"', className)) return const JSString();
- if (JS('bool', '# == "int"', int)) return const JSInt();
- if (JS('bool', '# == "double"', int)) return const JSDouble();
- if (JS('bool', '# == "num"', int)) return const JSNumber();
- if (JS('bool', '# == "bool"', int)) return const JSBool();
- if (JS('bool', '# == "List"', int)) return const JSArray();
+ if (JS('bool', '# == "int"', className)) return const JSInt();
+ if (JS('bool', '# == "double"', className)) return const JSDouble();
+ if (JS('bool', '# == "num"', className)) return const JSNumber();
+ if (JS('bool', '# == "bool"', className)) return const JSBool();
+ if (JS('bool', '# == "List"', className)) return const JSArray();
return JS('var', '#[#]', JS_CURRENT_ISOLATE(), className);
}

Powered by Google App Engine
This is Rietveld 408576698