| 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.source_library_builder; | 5 library fasta.source_library_builder; |
| 6 | 6 |
| 7 import 'package:front_end/src/scanner/token.dart' show Token; | 7 import 'package:front_end/src/scanner/token.dart' show Token; |
| 8 | 8 |
| 9 import 'package:kernel/ast.dart' show ProcedureKind; | 9 import 'package:kernel/ast.dart' show ProcedureKind; |
| 10 | 10 |
| (...skipping 501 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 512 final DeclarationBuilder<T> parent; | 512 final DeclarationBuilder<T> parent; |
| 513 | 513 |
| 514 final Map<String, Builder> members; | 514 final Map<String, Builder> members; |
| 515 | 515 |
| 516 final Map<String, Builder> constructors; | 516 final Map<String, Builder> constructors; |
| 517 | 517 |
| 518 final Map<String, Builder> setters; | 518 final Map<String, Builder> setters; |
| 519 | 519 |
| 520 final List<T> types = <T>[]; | 520 final List<T> types = <T>[]; |
| 521 | 521 |
| 522 final String name; | 522 String name; |
| 523 | 523 |
| 524 final Map<ProcedureBuilder, DeclarationBuilder<T>> factoryDeclarations; | 524 final Map<ProcedureBuilder, DeclarationBuilder<T>> factoryDeclarations; |
| 525 | 525 |
| 526 DeclarationBuilder(this.members, this.setters, this.constructors, | 526 DeclarationBuilder(this.members, this.setters, this.constructors, |
| 527 this.factoryDeclarations, this.name, this.parent); | 527 this.factoryDeclarations, this.name, this.parent); |
| 528 | 528 |
| 529 DeclarationBuilder.library() | 529 DeclarationBuilder.library() |
| 530 : this(<String, Builder>{}, <String, Builder>{}, null, null, null, null); | 530 : this(<String, Builder>{}, <String, Builder>{}, null, null, null, null); |
| 531 | 531 |
| 532 DeclarationBuilder createNested(String name, bool hasMembers) { | 532 DeclarationBuilder createNested(String name, bool hasMembers) { |
| (...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 599 /// synthesize type variables on the factory matching the class'. | 599 /// synthesize type variables on the factory matching the class'. |
| 600 void addFactoryDeclaration( | 600 void addFactoryDeclaration( |
| 601 ProcedureBuilder procedure, DeclarationBuilder<T> factoryDeclaration) { | 601 ProcedureBuilder procedure, DeclarationBuilder<T> factoryDeclaration) { |
| 602 factoryDeclarations[procedure] = factoryDeclaration; | 602 factoryDeclarations[procedure] = factoryDeclaration; |
| 603 } | 603 } |
| 604 | 604 |
| 605 Scope toScope(Scope parent) { | 605 Scope toScope(Scope parent) { |
| 606 return new Scope(members, setters, parent, isModifiable: false); | 606 return new Scope(members, setters, parent, isModifiable: false); |
| 607 } | 607 } |
| 608 } | 608 } |
| OLD | NEW |