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

Unified Diff: pkg/compiler/lib/src/js_emitter/model.dart

Issue 1252533003: dart2js: fix named arguments with Function.apply in the startup emitter. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Address comments Created 5 years, 5 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: pkg/compiler/lib/src/js_emitter/model.dart
diff --git a/pkg/compiler/lib/src/js_emitter/model.dart b/pkg/compiler/lib/src/js_emitter/model.dart
index 0a4facb3c01f184c6962b3eee22211e8fcf8457a..fe83370496d3458e85ba1e5188388dc07124838d 100644
--- a/pkg/compiler/lib/src/js_emitter/model.dart
+++ b/pkg/compiler/lib/src/js_emitter/model.dart
@@ -433,7 +433,11 @@ class InstanceMethod extends DartMethod {
/// ensure that this method is registered on the prototype under both [name]
/// and [aliasName].
final js.Name aliasName;
- final bool isClosure;
+
+ /// True if this is the implicit `call` instance method of an anonymous
+ /// closure. This predicate is false for explicit `call` methods and for
+ /// functions that can be torn off.
+ final bool isClosureCallMethod;
InstanceMethod(Element element, js.Name name, js.Expression code,
@@ -446,7 +450,7 @@ class InstanceMethod extends DartMethod {
bool canBeReflected,
int requiredParameterCount,
/* List | Map */ optionalParameterDefaultValues,
- this.isClosure,
+ this.isClosureCallMethod,
js.Expression functionType})
: super(element, name, code, parameterStubs, callName,
needsTearOff: needsTearOff,
@@ -456,7 +460,7 @@ class InstanceMethod extends DartMethod {
requiredParameterCount: requiredParameterCount,
optionalParameterDefaultValues: optionalParameterDefaultValues,
functionType: functionType) {
- assert(isClosure != null);
+ assert(isClosureCallMethod != null);
}
bool get isStatic => false;

Powered by Google App Engine
This is Rietveld 408576698