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

Side by Side Diff: lib/src/js/nodes.dart

Issue 1200233004: fixes #168, dart:js implementation with a test (Closed) Base URL: git@github.com:dart-lang/dev_compiler.git@master
Patch Set: fix error (window not defined) Created 5 years, 6 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 unified diff | Download patch
« no previous file with comments | « lib/src/dependency_graph.dart ('k') | test/browser/dom.dart » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 part of js_ast; 5 part of js_ast;
6 6
7 abstract class NodeVisitor<T> { 7 abstract class NodeVisitor<T> {
8 T visitProgram(Program node); 8 T visitProgram(Program node);
9 9
10 T visitBlock(Block node); 10 T visitBlock(Block node);
(...skipping 908 matching lines...) Expand 10 before | Expand all | Expand 10 after
919 class RestParameter extends Expression implements Parameter { 919 class RestParameter extends Expression implements Parameter {
920 final Identifier parameter; 920 final Identifier parameter;
921 921
922 RestParameter(this.parameter); 922 RestParameter(this.parameter);
923 923
924 RestParameter _clone() => new RestParameter(parameter); 924 RestParameter _clone() => new RestParameter(parameter);
925 accept(NodeVisitor visitor) => visitor.visitRestParameter(this); 925 accept(NodeVisitor visitor) => visitor.visitRestParameter(this);
926 void visitChildren(NodeVisitor visitor) { 926 void visitChildren(NodeVisitor visitor) {
927 parameter.accept(visitor); 927 parameter.accept(visitor);
928 } 928 }
929 int get precedenceLevel => SPREAD; 929 int get precedenceLevel => PRIMARY;
930 } 930 }
931 931
932 class This extends Expression { 932 class This extends Expression {
933 accept(NodeVisitor visitor) => visitor.visitThis(this); 933 accept(NodeVisitor visitor) => visitor.visitThis(this);
934 This _clone() => new This(); 934 This _clone() => new This();
935 int get precedenceLevel => PRIMARY; 935 int get precedenceLevel => PRIMARY;
936 void visitChildren(NodeVisitor visitor) {} 936 void visitChildren(NodeVisitor visitor) {}
937 } 937 }
938 938
939 // `super` is more restricted in the ES6 spec, but for simplicity we accept 939 // `super` is more restricted in the ES6 spec, but for simplicity we accept
(...skipping 522 matching lines...) Expand 10 before | Expand all | Expand 10 after
1462 final Expression expression; 1462 final Expression expression;
1463 1463
1464 CommentExpression(this.comment, this.expression); 1464 CommentExpression(this.comment, this.expression);
1465 1465
1466 int get precedenceLevel => PRIMARY; 1466 int get precedenceLevel => PRIMARY;
1467 accept(NodeVisitor visitor) => visitor.visitCommentExpression(this); 1467 accept(NodeVisitor visitor) => visitor.visitCommentExpression(this);
1468 CommentExpression _clone() => new CommentExpression(comment, expression); 1468 CommentExpression _clone() => new CommentExpression(comment, expression);
1469 1469
1470 void visitChildren(NodeVisitor visitor) => expression.accept(visitor); 1470 void visitChildren(NodeVisitor visitor) => expression.accept(visitor);
1471 } 1471 }
OLDNEW
« no previous file with comments | « lib/src/dependency_graph.dart ('k') | test/browser/dom.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698