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.kernel_formal_parameter_builder; | 5 library fasta.kernel_formal_parameter_builder; |
6 | 6 |
7 import 'package:kernel/ast.dart' show DynamicType, VariableDeclaration; | 7 import 'package:kernel/ast.dart' show DynamicType, VariableDeclaration; |
8 | 8 |
9 import 'kernel_builder.dart' | 9 import 'kernel_builder.dart' |
10 show | 10 show |
(...skipping 16 matching lines...) Expand all Loading... |
27 bool hasThis, | 27 bool hasThis, |
28 KernelLibraryBuilder compilationUnit, | 28 KernelLibraryBuilder compilationUnit, |
29 this.charOffset) | 29 this.charOffset) |
30 : super(metadata, modifiers, type, name, hasThis, compilationUnit, | 30 : super(metadata, modifiers, type, name, hasThis, compilationUnit, |
31 charOffset); | 31 charOffset); |
32 | 32 |
33 VariableDeclaration build(LibraryBuilder library) { | 33 VariableDeclaration build(LibraryBuilder library) { |
34 return declaration ??= new VariableDeclaration(name, | 34 return declaration ??= new VariableDeclaration(name, |
35 type: type?.build(library) ?? const DynamicType(), | 35 type: type?.build(library) ?? const DynamicType(), |
36 isFinal: isFinal, | 36 isFinal: isFinal, |
37 isConst: isConst)..fileOffset = charOffset; | 37 isConst: isConst) |
| 38 ..fileOffset = charOffset; |
38 } | 39 } |
39 | 40 |
40 VariableDeclaration get target => declaration; | 41 VariableDeclaration get target => declaration; |
41 } | 42 } |
OLD | NEW |