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

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

Issue 10441071: Use the typedef arity to know how to invoke a closure given by the dom. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/
Patch Set: Created 8 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: dart/lib/compiler/implementation/typechecker.dart
===================================================================
--- dart/lib/compiler/implementation/typechecker.dart (revision 8049)
+++ dart/lib/compiler/implementation/typechecker.dart (working copy)
@@ -105,6 +105,12 @@
}
SourceString get name() => const SourceString('Function');
+
+ int computeArity() {
+ int arity = 0;
+ parameterTypes.forEach((_) { arity++; });
+ return arity;
+ }
}
class Types {

Powered by Google App Engine
This is Rietveld 408576698