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

Side by Side Diff: pkg/compiler/lib/src/tree/unparser.dart

Issue 1873823002: Update elements, nodes and visitors for serialization. (Closed) Base URL: https://github.com/dart-lang/sdk.git@master
Patch Set: Rebased Created 4 years, 8 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 | « pkg/compiler/lib/src/tree/prettyprint.dart ('k') | pkg/compiler/lib/src/typechecker.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 import '../tokens/token.dart' show BeginGroupToken, Token; 5 import '../tokens/token.dart' show BeginGroupToken, Token;
6 import '../tokens/token_constants.dart' as Tokens 6 import '../tokens/token_constants.dart' as Tokens
7 show IDENTIFIER_TOKEN, KEYWORD_TOKEN, PLUS_TOKEN; 7 show IDENTIFIER_TOKEN, KEYWORD_TOKEN, PLUS_TOKEN;
8 import '../util/util.dart'; 8 import '../util/util.dart';
9 import 'nodes.dart'; 9 import 'nodes.dart';
10 10
(...skipping 621 matching lines...) Expand 10 before | Expand all | Expand 10 after
632 } 632 }
633 633
634 visitBreakStatement(BreakStatement node) { 634 visitBreakStatement(BreakStatement node) {
635 visitGotoStatement(node); 635 visitGotoStatement(node);
636 } 636 }
637 637
638 visitContinueStatement(ContinueStatement node) { 638 visitContinueStatement(ContinueStatement node) {
639 visitGotoStatement(node); 639 visitGotoStatement(node);
640 } 640 }
641 641
642 visitAsyncForIn(AsyncForIn node) { 642 visitForIn(ForIn node) {
643 write(node.awaitToken.value);
644 write(' ');
645 write(node.forToken.value); 643 write(node.forToken.value);
646 space(); 644 space();
647 write('('); 645 write('(');
648 visit(node.declaredIdentifier); 646 visit(node.declaredIdentifier);
649 write(' '); 647 write(' ');
650 addToken(node.inToken); 648 addToken(node.inToken);
651 visit(node.expression); 649 visit(node.expression);
652 write(')'); 650 write(')');
653 space(); 651 space();
654 visit(node.body); 652 visit(node.body);
655 } 653 }
656 654
655 visitAsyncForIn(AsyncForIn node) {
656 write(node.awaitToken.value);
657 write(' ');
658 visitForIn(node);
659 }
660
657 visitSyncForIn(SyncForIn node) { 661 visitSyncForIn(SyncForIn node) {
658 write(node.forToken.value); 662 visitForIn(node);
659 space();
660 write('(');
661 visit(node.declaredIdentifier);
662 write(' ');
663 addToken(node.inToken);
664 visit(node.expression);
665 write(')');
666 space();
667 visit(node.body);
668 } 663 }
669 664
670 visitLabel(Label node) { 665 visitLabel(Label node) {
671 visit(node.identifier); 666 visit(node.identifier);
672 write(node.colonToken.value); 667 write(node.colonToken.value);
673 } 668 }
674 669
675 visitLabeledStatement(LabeledStatement node) { 670 visitLabeledStatement(LabeledStatement node) {
676 visit(node.labels); 671 visit(node.labels);
677 visit(node.statement); 672 visit(node.statement);
(...skipping 223 matching lines...) Expand 10 before | Expand all | Expand 10 after
901 } 896 }
902 897
903 visitStatement(Statement node) { 898 visitStatement(Statement node) {
904 throw 'internal error'; // Should not be called. 899 throw 'internal error'; // Should not be called.
905 } 900 }
906 901
907 visitStringNode(StringNode node) { 902 visitStringNode(StringNode node) {
908 throw 'internal error'; // Should not be called. 903 throw 'internal error'; // Should not be called.
909 } 904 }
910 } 905 }
OLDNEW
« no previous file with comments | « pkg/compiler/lib/src/tree/prettyprint.dart ('k') | pkg/compiler/lib/src/typechecker.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698