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

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

Issue 10824401: Fix type annotation in the typechecker. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: lib/compiler/implementation/typechecker.dart
diff --git a/lib/compiler/implementation/typechecker.dart b/lib/compiler/implementation/typechecker.dart
index a5489eedaaff9abb5f814cad83d1e11d1d80fb65..b01a79391b6938e9e1b5ef9f32ec0e889aa2d39d 100644
--- a/lib/compiler/implementation/typechecker.dart
+++ b/lib/compiler/implementation/typechecker.dart
@@ -464,14 +464,15 @@ class TypeCheckerVisitor implements Visitor<Type> {
return types.dynamicType;
}
- void analyzeArguments(Send send, FunctionType funType) {
+ void analyzeArguments(Send send, Type type) {
Link<Node> arguments = send.arguments;
- if (funType === null || funType === types.dynamicType) {
+ if (type === null || type === types.dynamicType) {
while(!arguments.isEmpty()) {
analyze(arguments.head);
arguments = arguments.tail;
}
} else {
+ FunctionType funType = type;
Link<Type> parameterTypes = funType.parameterTypes;
while (!arguments.isEmpty() && !parameterTypes.isEmpty()) {
checkAssignable(arguments.head, parameterTypes.head,
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698