| 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.md file. | 3 // BSD-style license that can be found in the LICENSE.md file. |
| 4 | 4 |
| 5 import 'dart:collection' show Queue; | 5 import 'dart:collection' show Queue; |
| 6 | 6 |
| 7 import 'package:kernel/ast.dart' as ir; | 7 import 'package:kernel/ast.dart' as ir; |
| 8 import 'package:kernel/verifier.dart' show CheckParentPointers; | 8 import 'package:kernel/verifier.dart' show CheckParentPointers; |
| 9 | 9 |
| 10 import '../common.dart'; | 10 import '../common.dart'; |
| (...skipping 333 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 344 } | 344 } |
| 345 | 345 |
| 346 List<ir.Supertype> supertypesToIr(List<ResolutionDartType> types) { | 346 List<ir.Supertype> supertypesToIr(List<ResolutionDartType> types) { |
| 347 List<ir.Supertype> result = new List<ir.Supertype>(types.length); | 347 List<ir.Supertype> result = new List<ir.Supertype>(types.length); |
| 348 for (int i = 0; i < types.length; i++) { | 348 for (int i = 0; i < types.length; i++) { |
| 349 result[i] = supertypeToIr(types[i]); | 349 result[i] = supertypeToIr(types[i]); |
| 350 } | 350 } |
| 351 return result; | 351 return result; |
| 352 } | 352 } |
| 353 | 353 |
| 354 // ignore: MISSING_RETURN |
| 354 ir.DartType typeToIr(ResolutionDartType type) { | 355 ir.DartType typeToIr(ResolutionDartType type) { |
| 355 switch (type.kind) { | 356 switch (type.kind) { |
| 356 case ResolutionTypeKind.FUNCTION: | 357 case ResolutionTypeKind.FUNCTION: |
| 357 return functionTypeToIr(type); | 358 return functionTypeToIr(type); |
| 358 | 359 |
| 359 case ResolutionTypeKind.INTERFACE: | 360 case ResolutionTypeKind.INTERFACE: |
| 360 return interfaceTypeToIr(type); | 361 return interfaceTypeToIr(type); |
| 361 | 362 |
| 362 case ResolutionTypeKind.TYPEDEF: | 363 case ResolutionTypeKind.TYPEDEF: |
| 363 type.computeUnaliased(compiler.resolution); | 364 type.computeUnaliased(compiler.resolution); |
| (...skipping 415 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 779 } | 780 } |
| 780 | 781 |
| 781 class ConstructorTarget { | 782 class ConstructorTarget { |
| 782 final ConstructorElement element; | 783 final ConstructorElement element; |
| 783 final ResolutionDartType type; | 784 final ResolutionDartType type; |
| 784 | 785 |
| 785 ConstructorTarget(this.element, this.type); | 786 ConstructorTarget(this.element, this.type); |
| 786 | 787 |
| 787 String toString() => "ConstructorTarget($element, $type)"; | 788 String toString() => "ConstructorTarget($element, $type)"; |
| 788 } | 789 } |
| OLD | NEW |