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

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

Issue 13084013: Handle assignability for Send and SendSet (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Fix dart2dart bugs. Created 7 years, 7 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 c6a7a9a0424783019407559bf0b0d0e4cb8d88fe..5b945d75791be38df4b0ce40cf5962306cf5f690 100644
--- a/sdk/lib/_internal/compiler/implementation/resolution/members.dart
+++ b/sdk/lib/_internal/compiler/implementation/resolution/members.dart
@@ -876,7 +876,7 @@ class ResolverTask extends CompilerTask {
// TODO(johnniwinther): Store the mapping in the resolution enqueuer.
element.mapping = mapping;
return compiler.withCurrentElement(element, () {
- measure(() {
+ return measure(() {
Typedef node =
compiler.parser.measure(() => element.parseNode(compiler));
TypedefResolverVisitor visitor =
@@ -2201,6 +2201,10 @@ class ResolverVisitor extends MappingVisitor<Element> {
compiler.backend.registerClassUsingVariableExpression(cls);
compiler.backend.registerTypeVariableExpression(mapping);
} else if (target.impliesType() && !sendIsMemberAccess) {
+ // Set the type of the node to [Type] to mark this send as a
+ // type literal.
+ mapping.setType(node, compiler.typeClass.computeType(compiler));
+ world.registerInstantiatedClass(compiler.typeClass, mapping);
compiler.backend.registerTypeLiteral(mapping);
}
}
« no previous file with comments | « sdk/lib/_internal/compiler/implementation/dart_types.dart ('k') | sdk/lib/_internal/compiler/implementation/typechecker.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698