| OLD | NEW |
| 1 // Copyright (c) 2015, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2015, 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 library dev_compiler.src.codegen.ast_builder; | |
| 6 | |
| 7 import 'package:analyzer/src/generated/ast.dart'; | 5 import 'package:analyzer/src/generated/ast.dart'; |
| 8 import 'package:analyzer/src/generated/scanner.dart'; | 6 import 'package:analyzer/src/generated/scanner.dart'; |
| 9 import 'package:analyzer/src/generated/utilities_dart.dart'; | 7 import 'package:analyzer/src/generated/utilities_dart.dart'; |
| 10 import 'package:logging/logging.dart' as logger; | 8 import 'package:logging/logging.dart' as logger; |
| 11 | 9 |
| 12 final _log = new logger.Logger('dev_compiler.ast_builder'); | 10 final _log = new logger.Logger('dev_compiler.ast_builder'); |
| 13 | 11 |
| 14 // Wrappers around constructors for the dart ast. The AstBuilder class | 12 // Wrappers around constructors for the dart ast. The AstBuilder class |
| 15 // provides a higher-level interface, abstracting both from the lexical | 13 // provides a higher-level interface, abstracting both from the lexical |
| 16 // details and some of helper classes. The RawAstBuilder class provides | 14 // details and some of helper classes. The RawAstBuilder class provides |
| (...skipping 569 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 586 Label l = new Label(s, new Token(TokenType.COLON, 0)); | 584 Label l = new Label(s, new Token(TokenType.COLON, 0)); |
| 587 return new NamedExpression(l, e); | 585 return new NamedExpression(l, e); |
| 588 } | 586 } |
| 589 | 587 |
| 590 static VariableDeclarationStatement variableDeclarationStatement( | 588 static VariableDeclarationStatement variableDeclarationStatement( |
| 591 VariableDeclarationList varDecl) { | 589 VariableDeclarationList varDecl) { |
| 592 var semi = new Token(TokenType.SEMICOLON, 0); | 590 var semi = new Token(TokenType.SEMICOLON, 0); |
| 593 return new VariableDeclarationStatement(varDecl, semi); | 591 return new VariableDeclarationStatement(varDecl, semi); |
| 594 } | 592 } |
| 595 } | 593 } |
| OLD | NEW |