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

Unified Diff: sdk/lib/_internal/lib/js_rti.dart

Issue 82693004: Fix function subtyping bug. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Updated cf. comments. Created 7 years, 1 month 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 | tests/language/function_subtype2_test.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sdk/lib/_internal/lib/js_rti.dart
diff --git a/sdk/lib/_internal/lib/js_rti.dart b/sdk/lib/_internal/lib/js_rti.dart
index d8feff58b943d0612dd801b591c1b78a749fcb52..d090dea84dc364d3fe516a582b27326e9e72f176 100644
--- a/sdk/lib/_internal/lib/js_rti.dart
+++ b/sdk/lib/_internal/lib/js_rti.dart
@@ -675,11 +675,11 @@ bool isFunctionSubtype(var s, var t) {
return false;
}
}
- sPos = 0;
- // Check the optional parameters of [t] with the remaing optional parameters
- // of [s]:
+ tPos = 0;
+ // Check the optional parameters of [t] with the remaining optional
+ // parameters of [s]:
for (; tPos < tOptionalParametersLen ; sPos++, tPos++) {
- if (!isAssignable(getIndex(tOptionalParameterTypes, sPos),
+ if (!isAssignable(getIndex(sOptionalParameterTypes, sPos),
getIndex(tOptionalParameterTypes, tPos))) {
return false;
}
« no previous file with comments | « no previous file | tests/language/function_subtype2_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698