| 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.element_store; | 5 library fasta.analyzer.element_store; |
| 6 | 6 |
| 7 import 'package:kernel/analyzer/loader.dart' show | 7 import 'package:kernel/analyzer/loader.dart' show |
| 8 ReferenceLevelLoader; | 8 ReferenceLevelLoader; |
| 9 | 9 |
| 10 import 'package:kernel/ast.dart'; | 10 import 'package:kernel/ast.dart'; |
| (...skipping 226 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 237 class KernelParameterElement extends MockParameterElement { | 237 class KernelParameterElement extends MockParameterElement { |
| 238 final VariableDeclaration declaration; | 238 final VariableDeclaration declaration; |
| 239 | 239 |
| 240 final ParameterKind parameterKind; | 240 final ParameterKind parameterKind; |
| 241 | 241 |
| 242 KernelParameterElement(this.declaration, this.parameterKind); | 242 KernelParameterElement(this.declaration, this.parameterKind); |
| 243 } | 243 } |
| 244 | 244 |
| 245 /// Both an [Element] and [Builder] to using memory to store local elements in | 245 /// Both an [Element] and [Builder] to using memory to store local elements in |
| 246 /// [ElementStore]. | 246 /// [ElementStore]. |
| 247 class AnalyzerLocalVariableElemment extends MockElement with Builder | 247 class AnalyzerLocalVariableElemment extends MockElement |
| 248 implements LocalVariableElement { | 248 implements LocalVariableElement { |
| 249 final analyzer.VariableDeclaration variable; | 249 final analyzer.VariableDeclaration variable; |
| 250 | 250 |
| 251 AnalyzerLocalVariableElemment(this.variable) | 251 AnalyzerLocalVariableElemment(this.variable) |
| 252 : super(ElementKind.LOCAL_VARIABLE); | 252 : super(ElementKind.LOCAL_VARIABLE); |
| 253 | 253 |
| 254 String get name => variable.name.name; | 254 String get name => variable.name.name; |
| 255 | 255 |
| 256 bool get isFinal => false; // TODO(ahe): implement this. | 256 bool get isFinal => false; // TODO(ahe): implement this. |
| 257 | 257 |
| 258 bool get isConst => false; // TODO(ahe): implement this. | 258 bool get isConst => false; // TODO(ahe): implement this. |
| 259 | 259 |
| 260 analyzer.VariableDeclaration get target => variable; | 260 analyzer.VariableDeclaration get target => variable; |
| 261 } | 261 } |
| 262 | 262 |
| 263 /// Both an [Element] and [Builder] to using memory to store local elements in | 263 /// Both an [Element] and [Builder] to using memory to store local elements in |
| 264 /// [ElementStore]. | 264 /// [ElementStore]. |
| 265 class AnalyzerParameterElement extends MockParameterElement with Builder { | 265 class AnalyzerParameterElement extends MockParameterElement { |
| 266 final analyzer.FormalParameter parameter; | 266 final analyzer.FormalParameter parameter; |
| 267 | 267 |
| 268 AnalyzerParameterElement(this.parameter); | 268 AnalyzerParameterElement(this.parameter); |
| 269 | 269 |
| 270 String get name => parameter.identifier.name; | 270 String get name => parameter.identifier.name; |
| 271 | 271 |
| 272 bool get isFinal => false; // TODO(ahe): implement this. | 272 bool get isFinal => false; // TODO(ahe): implement this. |
| 273 | 273 |
| 274 bool get isConst => false; // TODO(ahe): implement this. | 274 bool get isConst => false; // TODO(ahe): implement this. |
| 275 | 275 |
| (...skipping 10 matching lines...) Expand all Loading... |
| 286 } | 286 } |
| 287 } | 287 } |
| 288 | 288 |
| 289 class KernelInterfaceType extends MockInterfaceType { | 289 class KernelInterfaceType extends MockInterfaceType { |
| 290 final KernelClassElement element; | 290 final KernelClassElement element; |
| 291 | 291 |
| 292 KernelInterfaceType(this.element); | 292 KernelInterfaceType(this.element); |
| 293 | 293 |
| 294 List<analyzer.DartType> get typeArguments => const <analyzer.DartType>[]; | 294 List<analyzer.DartType> get typeArguments => const <analyzer.DartType>[]; |
| 295 } | 295 } |
| OLD | NEW |