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

Unified Diff: sdk/lib/_internal/compiler/implementation/tree_validator.dart

Issue 12751002: Support optional function expression parameters in dart2js. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Added spaces around ternary operator. Created 7 years, 9 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 | « sdk/lib/_internal/compiler/implementation/resolution/members.dart ('k') | tests/co19/co19-dart2dart.status » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sdk/lib/_internal/compiler/implementation/tree_validator.dart
diff --git a/sdk/lib/_internal/compiler/implementation/tree_validator.dart b/sdk/lib/_internal/compiler/implementation/tree_validator.dart
index 6a3b93f3776e779cde22c1f0b7ea12ec6c35abba..ce3809eb8559c80d0b90c936e7f7fe27a16a649a 100644
--- a/sdk/lib/_internal/compiler/implementation/tree_validator.dart
+++ b/sdk/lib/_internal/compiler/implementation/tree_validator.dart
@@ -42,7 +42,9 @@ class ValidatorVisitor extends Visitor {
final arguments = node.arguments;
expect(node, arguments != null);
- expect(node, selector is Identifier, 'selector is not assignable');
+ expect(node,
+ selector is Identifier || selector is FunctionExpression,
+ 'selector is not assignable');
if (identical(name, '++') || identical(name, '--')) {
expect(node, node.assignmentOperator is Operator);
if (node.isIndex) {
« no previous file with comments | « sdk/lib/_internal/compiler/implementation/resolution/members.dart ('k') | tests/co19/co19-dart2dart.status » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698