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

Unified Diff: dart/lib/compiler/implementation/typechecker.dart

Issue 10661029: Ensure interfaces are loaded. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge
Patch Set: Rebased Created 8 years, 4 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 | « dart/lib/compiler/implementation/resolver.dart ('k') | dart/lib/compiler/implementation/world.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: dart/lib/compiler/implementation/typechecker.dart
diff --git a/dart/lib/compiler/implementation/typechecker.dart b/dart/lib/compiler/implementation/typechecker.dart
index 9344d233a888ae4952a10597793b9728a97218d7..28eb3d1aa619cfaa40552710932c7c6418596def 100644
--- a/dart/lib/compiler/implementation/typechecker.dart
+++ b/dart/lib/compiler/implementation/typechecker.dart
@@ -93,11 +93,11 @@ class InterfaceType implements Type {
class FunctionType implements Type {
final Element element;
- final Type returnType;
- final Link<Type> parameterTypes;
+ Type returnType;
+ Link<Type> parameterTypes;
- const FunctionType(Type this.returnType, Link<Type> this.parameterTypes,
- Element this.element);
+ FunctionType(Type this.returnType, Link<Type> this.parameterTypes,
+ Element this.element);
toString() {
StringBuffer sb = new StringBuffer();
@@ -115,6 +115,13 @@ class FunctionType implements Type {
parameterTypes.forEach((_) { arity++; });
return arity;
}
+
+ void initializeFrom(FunctionType other) {
+ assert(returnType === null);
+ assert(parameterTypes === null);
+ returnType = other.returnType;
+ parameterTypes = other.parameterTypes;
+ }
}
class Types {
« no previous file with comments | « dart/lib/compiler/implementation/resolver.dart ('k') | dart/lib/compiler/implementation/world.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698