| OLD | NEW |
| 1 // Copyright (c) 2016, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2016, 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 fasta.analyzer.ast_builder; | 5 library fasta.analyzer.ast_builder; |
| 6 | 6 |
| 7 import 'package:analyzer/analyzer.dart'; | 7 import 'package:analyzer/analyzer.dart'; |
| 8 import 'package:analyzer/dart/ast/ast_factory.dart' show AstFactory; | 8 import 'package:analyzer/dart/ast/ast_factory.dart' show AstFactory; |
| 9 import 'package:analyzer/dart/ast/standard_ast_factory.dart' as standard; | 9 import 'package:analyzer/dart/ast/standard_ast_factory.dart' as standard; |
| 10 import 'package:analyzer/dart/ast/token.dart' as analyzer show Token; | 10 import 'package:analyzer/dart/ast/token.dart' as analyzer show Token; |
| (...skipping 1589 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1600 ast.simpleIdentifier(returnType.token), | 1600 ast.simpleIdentifier(returnType.token), |
| 1601 period, | 1601 period, |
| 1602 name, | 1602 name, |
| 1603 parameters, | 1603 parameters, |
| 1604 toAnalyzerToken(separator), | 1604 toAnalyzerToken(separator), |
| 1605 null, | 1605 null, |
| 1606 redirectedConstructor, | 1606 redirectedConstructor, |
| 1607 body)); | 1607 body)); |
| 1608 } | 1608 } |
| 1609 | 1609 |
| 1610 void endFieldInitializer(Token assignment) { | 1610 void endFieldInitializer(Token assignment, Token token) { |
| 1611 debugEvent("FieldInitializer"); | 1611 debugEvent("FieldInitializer"); |
| 1612 Expression initializer = pop(); | 1612 Expression initializer = pop(); |
| 1613 SimpleIdentifier name = pop(); | 1613 SimpleIdentifier name = pop(); |
| 1614 push(ast.variableDeclaration( | 1614 push(ast.variableDeclaration( |
| 1615 name, toAnalyzerToken(assignment), initializer)); | 1615 name, toAnalyzerToken(assignment), initializer)); |
| 1616 } | 1616 } |
| 1617 | 1617 |
| 1618 @override | 1618 @override |
| 1619 void endFunction(Token getOrSet, Token endToken) { | 1619 void endFunction(Token getOrSet, Token endToken) { |
| 1620 debugEvent("Function"); | 1620 debugEvent("Function"); |
| (...skipping 459 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2080 } else if (identical('static', s)) { | 2080 } else if (identical('static', s)) { |
| 2081 staticKeyword = token; | 2081 staticKeyword = token; |
| 2082 } else if (identical('var', s)) { | 2082 } else if (identical('var', s)) { |
| 2083 finalConstOrVarKeyword = token; | 2083 finalConstOrVarKeyword = token; |
| 2084 } else { | 2084 } else { |
| 2085 internalError('Unhandled modifier: $s'); | 2085 internalError('Unhandled modifier: $s'); |
| 2086 } | 2086 } |
| 2087 } | 2087 } |
| 2088 } | 2088 } |
| 2089 } | 2089 } |
| OLD | NEW |