| OLD | NEW |
| 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 'dart:collection' show IterableMixin; | 5 import 'dart:collection' show IterableMixin; |
| 6 | 6 |
| 7 import 'package:front_end/src/fasta/fasta_codes.dart' show FastaMessage; | 7 import 'package:front_end/src/fasta/fasta_codes.dart' show FastaMessage; |
| 8 import 'package:front_end/src/fasta/scanner.dart' show BeginGroupToken, Token; | 8 import 'package:front_end/src/fasta/scanner.dart' show Token; |
| 9 import 'package:front_end/src/fasta/scanner/token_constants.dart' as Tokens | 9 import 'package:front_end/src/fasta/scanner/token_constants.dart' as Tokens |
| 10 show PLUS_TOKEN; | 10 show PLUS_TOKEN; |
| 11 import 'package:front_end/src/fasta/scanner/characters.dart'; | 11 import 'package:front_end/src/fasta/scanner/characters.dart'; |
| 12 import 'package:front_end/src/scanner/token.dart' show TokenType; | 12 import 'package:front_end/src/scanner/token.dart' show BeginToken, TokenType; |
| 13 | 13 |
| 14 import '../common.dart'; | 14 import '../common.dart'; |
| 15 import '../elements/elements.dart' show MetadataAnnotation; | 15 import '../elements/elements.dart' show MetadataAnnotation; |
| 16 import '../util/util.dart'; | 16 import '../util/util.dart'; |
| 17 import 'dartstring.dart'; | 17 import 'dartstring.dart'; |
| 18 import 'prettyprint.dart'; | 18 import 'prettyprint.dart'; |
| 19 import 'unparser.dart'; | 19 import 'unparser.dart'; |
| 20 | 20 |
| 21 abstract class Visitor<R> { | 21 abstract class Visitor<R> { |
| 22 const Visitor(); | 22 const Visitor(); |
| (...skipping 1896 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1919 if (body != null) body.accept1(visitor, arg); | 1919 if (body != null) body.accept1(visitor, arg); |
| 1920 } | 1920 } |
| 1921 | 1921 |
| 1922 Token getBeginToken() => whileKeyword; | 1922 Token getBeginToken() => whileKeyword; |
| 1923 | 1923 |
| 1924 Token getEndToken() => body.getEndToken(); | 1924 Token getEndToken() => body.getEndToken(); |
| 1925 } | 1925 } |
| 1926 | 1926 |
| 1927 class ParenthesizedExpression extends Expression { | 1927 class ParenthesizedExpression extends Expression { |
| 1928 final Expression expression; | 1928 final Expression expression; |
| 1929 final BeginGroupToken beginToken; | 1929 final BeginToken beginToken; |
| 1930 | 1930 |
| 1931 ParenthesizedExpression( | 1931 ParenthesizedExpression( |
| 1932 Expression this.expression, BeginGroupToken this.beginToken); | 1932 Expression this.expression, BeginToken this.beginToken); |
| 1933 | 1933 |
| 1934 ParenthesizedExpression asParenthesizedExpression() => this; | 1934 ParenthesizedExpression asParenthesizedExpression() => this; |
| 1935 | 1935 |
| 1936 accept(Visitor visitor) => visitor.visitParenthesizedExpression(this); | 1936 accept(Visitor visitor) => visitor.visitParenthesizedExpression(this); |
| 1937 | 1937 |
| 1938 accept1(Visitor1 visitor, arg) { | 1938 accept1(Visitor1 visitor, arg) { |
| 1939 return visitor.visitParenthesizedExpression(this, arg); | 1939 return visitor.visitParenthesizedExpression(this, arg); |
| 1940 } | 1940 } |
| 1941 | 1941 |
| 1942 visitChildren(Visitor visitor) { | 1942 visitChildren(Visitor visitor) { |
| (...skipping 1340 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3283 */ | 3283 */ |
| 3284 Object getTreeElement(TreeElementMixin node) => node._element; | 3284 Object getTreeElement(TreeElementMixin node) => node._element; |
| 3285 | 3285 |
| 3286 /** | 3286 /** |
| 3287 * Do not call this method directly. Instead, use an instance of | 3287 * Do not call this method directly. Instead, use an instance of |
| 3288 * TreeElements. | 3288 * TreeElements. |
| 3289 */ | 3289 */ |
| 3290 void setTreeElement(TreeElementMixin node, Object value) { | 3290 void setTreeElement(TreeElementMixin node, Object value) { |
| 3291 node._element = value; | 3291 node._element = value; |
| 3292 } | 3292 } |
| OLD | NEW |