Skip to content

Commit 7d2a27f

Browse files
scheglovCommit Queue
authored andcommitted
Elements. Deprecate V1 in dart/element/type_system.dart
Change-Id: I3059685ed6c92b12a8926d6f1a6b278970e8b457 Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/413001 Reviewed-by: Brian Wilkerson <[email protected]> Reviewed-by: Paul Berry <[email protected]> Commit-Queue: Konstantin Shcheglov <[email protected]>
1 parent 539840f commit 7d2a27f

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

pkg/analyzer/lib/dart/element/type_system.dart

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,6 @@
22
// for details. All rights reserved. Use of this source code is governed by a
33
// BSD-style license that can be found in the LICENSE file.
44

5-
// ignore_for_file: analyzer_use_new_elements, as_much_as_we_can
6-
75
import 'package:analyzer/dart/element/element.dart';
86
import 'package:analyzer/dart/element/element2.dart';
97
import 'package:analyzer/dart/element/nullability_suffix.dart';
@@ -45,6 +43,7 @@ abstract class TypeSystem {
4543
DartType greatestLowerBound(DartType T1, DartType T2);
4644

4745
/// Instantiate the given [element] with default type arguments.
46+
@Deprecated('Use instantiateInterfaceToBounds2() instead')
4847
InterfaceType instantiateInterfaceToBounds({
4948
required InterfaceElement element,
5049
required NullabilitySuffix nullabilitySuffix,
@@ -58,6 +57,7 @@ abstract class TypeSystem {
5857
});
5958

6059
/// Instantiate the given [element] with default type arguments.
60+
@Deprecated('Use instantiateTypeAliasToBounds2() instead')
6161
DartType instantiateTypeAliasToBounds({
6262
required TypeAliasElement element,
6363
required NullabilitySuffix nullabilitySuffix,

pkg/analyzer/lib/src/dart/element/type_system.dart

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -669,6 +669,7 @@ class TypeSystemImpl implements TypeSystem {
669669
return inferrer.chooseFinalTypes();
670670
}
671671

672+
@Deprecated('Use instantiateInterfaceToBounds2() instead')
672673
@override
673674
InterfaceTypeImpl instantiateInterfaceToBounds({
674675
required covariant InterfaceElementImpl element,
@@ -711,6 +712,7 @@ class TypeSystemImpl implements TypeSystem {
711712
}
712713
}
713714

715+
@Deprecated('Use instantiateTypeAliasToBounds2() instead')
714716
@override
715717
TypeImpl instantiateTypeAliasToBounds({
716718
required covariant TypeAliasElementImpl element,

0 commit comments

Comments
 (0)