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

Unified Diff: sdk/lib/_internal/compiler/implementation/resolution/members.dart

Issue 12334070: Support runtime check of function types. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Minor fix 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: sdk/lib/_internal/compiler/implementation/resolution/members.dart
diff --git a/sdk/lib/_internal/compiler/implementation/resolution/members.dart b/sdk/lib/_internal/compiler/implementation/resolution/members.dart
index e422dbe5bd756c7371f611d7f7d15a6993d305c7..04aa685fade9e6543db7053012bafd03d4c899a6 100644
--- a/sdk/lib/_internal/compiler/implementation/resolution/members.dart
+++ b/sdk/lib/_internal/compiler/implementation/resolution/members.dart
@@ -1901,6 +1901,12 @@ class ResolverVisitor extends MappingVisitor<Element> {
}
parameterNodes = parameterNodes.tail;
});
+ if (inCheckContext) {
+ functionParameters.forEachParameter((Element element) {
+ compiler.enqueuer.resolution.registerIsCheck(
+ element.computeType(compiler), mapping);
+ });
+ }
}
visitCascade(Cascade node) {
@@ -1998,6 +2004,7 @@ class ResolverVisitor extends MappingVisitor<Element> {
scope = oldScope;
enclosingElement = previousEnclosingElement;
+ world.registerClosurizedMember(function, mapping);
world.registerInstantiatedClass(compiler.functionClass, mapping);
}

Powered by Google App Engine
This is Rietveld 408576698