Skip to content

Commit c96a690

Browse files
committed
Auto merge of #143407 - jhpratt:rollup-ekkoubw, r=jhpratt
Rollup of 11 pull requests Successful merges: - #142749 (Add methods for converting bool to `Result<(), E>`) - #143288 (Fix `x clean` with a fifo) - #143307 (Fast path nitpicks) - #143346 (update coherence example) - #143356 (use unsigned_abs instead of `abs` on signed int to silence clippy) - #143370 (remove redundant #[must_use]) - #143378 (simplify receivers for some array method calls) - #143380 (Replace kw_span by full span for generic const parameters.) - #143381 (rustdoc: don't treat methods under const impls or traits as const) - #143394 (compiler: Document and reduce `fn provide`s in hir crates) - #143395 (Always use the pure Rust fallback instead of `llvm.{maximum,minimum}`) r? `@ghost` `@rustbot` modify labels: rollup
2 parents 837c5dd + e4e26d2 commit c96a690

File tree

43 files changed

+247
-125
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

43 files changed

+247
-125
lines changed

compiler/rustc_ast/src/ast.rs

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -385,8 +385,8 @@ pub enum GenericParamKind {
385385
},
386386
Const {
387387
ty: P<Ty>,
388-
/// Span of the `const` keyword.
389-
kw_span: Span,
388+
/// Span of the whole parameter definition, including default.
389+
span: Span,
390390
/// Optional default value for the const generic param.
391391
default: Option<AnonConst>,
392392
},
@@ -410,10 +410,7 @@ impl GenericParam {
410410
self.ident.span
411411
}
412412
GenericParamKind::Type { default: Some(ty) } => self.ident.span.to(ty.span),
413-
GenericParamKind::Const { kw_span, default: Some(default), .. } => {
414-
kw_span.to(default.value.span)
415-
}
416-
GenericParamKind::Const { kw_span, default: None, ty } => kw_span.to(ty.span),
413+
GenericParamKind::Const { span, .. } => *span,
417414
}
418415
}
419416
}

compiler/rustc_ast/src/visit.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1350,9 +1350,10 @@ macro_rules! common_visitor_and_walkers {
13501350
match kind {
13511351
GenericParamKind::Lifetime => (),
13521352
GenericParamKind::Type { default } => visit_opt!(vis, visit_ty, default),
1353-
GenericParamKind::Const { ty, default, kw_span: _ } => {
1353+
GenericParamKind::Const { ty, default, span } => {
13541354
try_visit!(vis.visit_ty(ty));
13551355
visit_opt!(vis, visit_anon_const, default);
1356+
try_visit!(visit_span(vis, span));
13561357
}
13571358
}
13581359
if let Some(sp) = colon_span {

compiler/rustc_ast_lowering/src/lib.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1960,7 +1960,7 @@ impl<'a, 'hir> LoweringContext<'a, 'hir> {
19601960

19611961
(hir::ParamName::Plain(self.lower_ident(param.ident)), kind)
19621962
}
1963-
GenericParamKind::Const { ty, kw_span: _, default } => {
1963+
GenericParamKind::Const { ty, span: _, default } => {
19641964
let ty = self
19651965
.lower_ty(ty, ImplTraitContext::Disallowed(ImplTraitPosition::GenericDefault));
19661966

compiler/rustc_ast_passes/src/ast_validation.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -909,11 +909,11 @@ fn validate_generic_param_order(dcx: DiagCtxtHandle<'_>, generics: &[GenericPara
909909
}
910910
GenericParamKind::Type { default: None } => (),
911911
GenericParamKind::Lifetime => (),
912-
GenericParamKind::Const { ty: _, kw_span: _, default: Some(default) } => {
912+
GenericParamKind::Const { ty: _, span: _, default: Some(default) } => {
913913
ordered_params += " = ";
914914
ordered_params += &pprust::expr_to_string(&default.value);
915915
}
916-
GenericParamKind::Const { ty: _, kw_span: _, default: None } => (),
916+
GenericParamKind::Const { ty: _, span: _, default: None } => (),
917917
}
918918
first = false;
919919
}

compiler/rustc_builtin_macros/src/deriving/coerce_pointee.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -124,7 +124,7 @@ pub(crate) fn expand_deriving_coerce_pointee(
124124
GenericParamKind::Type { default: _ } => {
125125
cx.typaram(p.span(), p.ident, p.bounds.clone(), None)
126126
}
127-
GenericParamKind::Const { ty, kw_span: _, default: _ } => cx
127+
GenericParamKind::Const { ty, span: _, default: _ } => cx
128128
.const_param(
129129
p.span(),
130130
p.ident,

compiler/rustc_builtin_macros/src/deriving/generic/mod.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -664,10 +664,10 @@ impl<'a> TraitDef<'a> {
664664

665665
cx.typaram(param.ident.span.with_ctxt(ctxt), param.ident, bounds, None)
666666
}
667-
GenericParamKind::Const { ty, kw_span, .. } => {
667+
GenericParamKind::Const { ty, span, .. } => {
668668
let const_nodefault_kind = GenericParamKind::Const {
669669
ty: ty.clone(),
670-
kw_span: kw_span.with_ctxt(ctxt),
670+
span: span.with_ctxt(ctxt),
671671

672672
// We can't have default values inside impl block
673673
default: None,

compiler/rustc_codegen_llvm/src/intrinsic.rs

Lines changed: 14 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -103,23 +103,25 @@ fn call_simple_intrinsic<'ll, 'tcx>(
103103
sym::minnumf64 => ("llvm.minnum", &[bx.type_f64()]),
104104
sym::minnumf128 => ("llvm.minnum", &[bx.type_f128()]),
105105

106-
sym::minimumf16 => ("llvm.minimum", &[bx.type_f16()]),
107-
sym::minimumf32 => ("llvm.minimum", &[bx.type_f32()]),
108-
sym::minimumf64 => ("llvm.minimum", &[bx.type_f64()]),
109-
// There are issues on x86_64 and aarch64 with the f128 variant,
110-
// let's instead use the intrinsic fallback body.
111-
// sym::minimumf128 => ("llvm.minimum", &[cx.type_f128()]),
106+
// FIXME: LLVM currently mis-compile those intrinsics, re-enable them
107+
// when llvm/llvm-project#{139380,139381,140445} are fixed.
108+
//sym::minimumf16 => ("llvm.minimum", &[bx.type_f16()]),
109+
//sym::minimumf32 => ("llvm.minimum", &[bx.type_f32()]),
110+
//sym::minimumf64 => ("llvm.minimum", &[bx.type_f64()]),
111+
//sym::minimumf128 => ("llvm.minimum", &[cx.type_f128()]),
112+
//
112113
sym::maxnumf16 => ("llvm.maxnum", &[bx.type_f16()]),
113114
sym::maxnumf32 => ("llvm.maxnum", &[bx.type_f32()]),
114115
sym::maxnumf64 => ("llvm.maxnum", &[bx.type_f64()]),
115116
sym::maxnumf128 => ("llvm.maxnum", &[bx.type_f128()]),
116117

117-
sym::maximumf16 => ("llvm.maximum", &[bx.type_f16()]),
118-
sym::maximumf32 => ("llvm.maximum", &[bx.type_f32()]),
119-
sym::maximumf64 => ("llvm.maximum", &[bx.type_f64()]),
120-
// There are issues on x86_64 and aarch64 with the f128 variant,
121-
// let's instead use the intrinsic fallback body.
122-
// sym::maximumf128 => ("llvm.maximum", &[cx.type_f128()]),
118+
// FIXME: LLVM currently mis-compile those intrinsics, re-enable them
119+
// when llvm/llvm-project#{139380,139381,140445} are fixed.
120+
//sym::maximumf16 => ("llvm.maximum", &[bx.type_f16()]),
121+
//sym::maximumf32 => ("llvm.maximum", &[bx.type_f32()]),
122+
//sym::maximumf64 => ("llvm.maximum", &[bx.type_f64()]),
123+
//sym::maximumf128 => ("llvm.maximum", &[cx.type_f128()]),
124+
//
123125
sym::copysignf16 => ("llvm.copysign", &[bx.type_f16()]),
124126
sym::copysignf32 => ("llvm.copysign", &[bx.type_f32()]),
125127
sym::copysignf64 => ("llvm.copysign", &[bx.type_f64()]),

compiler/rustc_expand/src/build.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -172,7 +172,7 @@ impl<'a> ExtCtxt<'a> {
172172
attrs: AttrVec::new(),
173173
bounds,
174174
is_placeholder: false,
175-
kind: ast::GenericParamKind::Const { ty, kw_span: DUMMY_SP, default },
175+
kind: ast::GenericParamKind::Const { ty, span: DUMMY_SP, default },
176176
colon_span: None,
177177
}
178178
}

compiler/rustc_hir_analysis/src/check/mod.rs

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -100,15 +100,17 @@ use self::compare_impl_item::collect_return_position_impl_trait_in_trait_tys;
100100
use self::region::region_scope_tree;
101101
use crate::{errors, require_c_abi_if_c_variadic};
102102

103-
pub fn provide(providers: &mut Providers) {
104-
wfcheck::provide(providers);
103+
/// Adds query implementations to the [Providers] vtable, see [`rustc_middle::query`]
104+
pub(super) fn provide(providers: &mut Providers) {
105105
*providers = Providers {
106106
adt_destructor,
107107
adt_async_destructor,
108108
region_scope_tree,
109109
collect_return_position_impl_trait_in_trait_tys,
110110
compare_impl_item: compare_impl_item::compare_impl_item,
111111
check_coroutine_obligations: check::check_coroutine_obligations,
112+
check_type_wf: wfcheck::check_type_wf,
113+
check_well_formed: wfcheck::check_well_formed,
112114
..*providers
113115
};
114116
}

compiler/rustc_hir_analysis/src/check/wfcheck.rs

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,6 @@ use rustc_infer::infer::{self, InferCtxt, SubregionOrigin, TyCtxtInferExt};
1515
use rustc_lint_defs::builtin::SUPERTRAIT_ITEM_SHADOWING_DEFINITION;
1616
use rustc_macros::LintDiagnostic;
1717
use rustc_middle::mir::interpret::ErrorHandled;
18-
use rustc_middle::query::Providers;
1918
use rustc_middle::traits::solve::NoSolution;
2019
use rustc_middle::ty::trait_def::TraitSpecializationKind;
2120
use rustc_middle::ty::{
@@ -189,7 +188,10 @@ where
189188
}
190189
}
191190

192-
fn check_well_formed(tcx: TyCtxt<'_>, def_id: LocalDefId) -> Result<(), ErrorGuaranteed> {
191+
pub(super) fn check_well_formed(
192+
tcx: TyCtxt<'_>,
193+
def_id: LocalDefId,
194+
) -> Result<(), ErrorGuaranteed> {
193195
let mut res = crate::check::check::check_item_type(tcx, def_id);
194196

195197
for param in &tcx.generics_of(def_id).own_params {
@@ -2249,7 +2251,7 @@ impl<'tcx> WfCheckingCtxt<'_, 'tcx> {
22492251
}
22502252
}
22512253

2252-
fn check_type_wf(tcx: TyCtxt<'_>, (): ()) -> Result<(), ErrorGuaranteed> {
2254+
pub(super) fn check_type_wf(tcx: TyCtxt<'_>, (): ()) -> Result<(), ErrorGuaranteed> {
22532255
let items = tcx.hir_crate_items(());
22542256
let res = items
22552257
.par_items(|item| tcx.ensure_ok().check_well_formed(item.owner_id.def_id))
@@ -2397,7 +2399,3 @@ struct RedundantLifetimeArgsLint<'tcx> {
23972399
// The lifetime we can replace the victim with.
23982400
candidate: ty::Region<'tcx>,
23992401
}
2400-
2401-
pub fn provide(providers: &mut Providers) {
2402-
*providers = Providers { check_type_wf, check_well_formed, ..*providers };
2403-
}

compiler/rustc_hir_analysis/src/check_unused.rs

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,11 @@
11
use rustc_data_structures::unord::{ExtendUnord, UnordSet};
22
use rustc_hir::def::DefKind;
33
use rustc_hir::def_id::LocalDefId;
4-
use rustc_middle::query::Providers;
54
use rustc_middle::ty::TyCtxt;
65
use rustc_session::lint;
76
use tracing::debug;
87

9-
pub(crate) fn provide(providers: &mut Providers) {
10-
*providers = Providers { check_unused_traits, ..*providers };
11-
}
12-
13-
fn check_unused_traits(tcx: TyCtxt<'_>, (): ()) {
8+
pub(super) fn check_unused_traits(tcx: TyCtxt<'_>, (): ()) {
149
let mut used_trait_imports = UnordSet::<LocalDefId>::default();
1510

1611
// FIXME: Use `tcx.hir_par_body_owners()` when we implement creating `DefId`s

compiler/rustc_hir_analysis/src/coherence/mod.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -130,6 +130,7 @@ fn enforce_empty_impls_for_marker_traits(
130130
.emit())
131131
}
132132

133+
/// Adds query implementations to the [Providers] vtable, see [`rustc_middle::query`].
133134
pub(crate) fn provide(providers: &mut Providers) {
134135
use self::builtin::coerce_unsized_info;
135136
use self::inherent_impls::{

compiler/rustc_hir_analysis/src/collect.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -61,6 +61,7 @@ mod type_of;
6161

6262
///////////////////////////////////////////////////////////////////////////
6363

64+
/// Adds query implementations to the [Providers] vtable, see [`rustc_middle::query`]
6465
pub(crate) fn provide(providers: &mut Providers) {
6566
resolve_bound_vars::provide(providers);
6667
*providers = Providers {

compiler/rustc_hir_analysis/src/collect/resolve_bound_vars.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -222,6 +222,7 @@ enum BinderScopeType {
222222

223223
type ScopeRef<'a> = &'a Scope<'a>;
224224

225+
/// Adds query implementations to the [Providers] vtable, see [`rustc_middle::query`]
225226
pub(crate) fn provide(providers: &mut Providers) {
226227
*providers = Providers {
227228
resolve_bound_vars,

compiler/rustc_hir_analysis/src/hir_wf_check.rs

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -4,21 +4,16 @@ use rustc_hir::{self as hir, AmbigArg, ForeignItem, ForeignItemKind};
44
use rustc_infer::infer::TyCtxtInferExt;
55
use rustc_infer::traits::{ObligationCause, ObligationCauseCode, WellFormedLoc};
66
use rustc_middle::bug;
7-
use rustc_middle::query::Providers;
87
use rustc_middle::ty::{self, TyCtxt, TypeVisitableExt, TypingMode, fold_regions};
98
use rustc_span::def_id::LocalDefId;
109
use rustc_trait_selection::traits::{self, ObligationCtxt};
1110
use tracing::debug;
1211

1312
use crate::collect::ItemCtxt;
1413

15-
pub(crate) fn provide(providers: &mut Providers) {
16-
*providers = Providers { diagnostic_hir_wf_check, ..*providers };
17-
}
18-
1914
// Ideally, this would be in `rustc_trait_selection`, but we
2015
// need access to `ItemCtxt`
21-
fn diagnostic_hir_wf_check<'tcx>(
16+
pub(super) fn diagnostic_hir_wf_check<'tcx>(
2217
tcx: TyCtxt<'tcx>,
2318
(predicate, loc): (ty::Predicate<'tcx>, WellFormedLoc),
2419
) -> Option<ObligationCause<'tcx>> {

compiler/rustc_hir_analysis/src/lib.rs

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -150,18 +150,21 @@ fn require_c_abi_if_c_variadic(
150150
.emit();
151151
}
152152

153+
/// Adds query implementations to the [Providers] vtable, see [`rustc_middle::query`]
153154
pub fn provide(providers: &mut Providers) {
154155
collect::provide(providers);
155156
coherence::provide(providers);
156157
check::provide(providers);
157-
check_unused::provide(providers);
158-
variance::provide(providers);
159-
outlives::provide(providers);
160-
hir_wf_check::provide(providers);
161158
*providers = Providers {
159+
check_unused_traits: check_unused::check_unused_traits,
160+
diagnostic_hir_wf_check: hir_wf_check::diagnostic_hir_wf_check,
161+
inferred_outlives_crate: outlives::inferred_outlives_crate,
162+
inferred_outlives_of: outlives::inferred_outlives_of,
162163
inherit_sig_for_delegation_item: delegation::inherit_sig_for_delegation_item,
163164
enforce_impl_non_lifetime_params_are_constrained:
164165
impl_wf_check::enforce_impl_non_lifetime_params_are_constrained,
166+
crate_variances: variance::crate_variances,
167+
variances_of: variance::variances_of,
165168
..*providers
166169
};
167170
}

compiler/rustc_hir_analysis/src/outlives/mod.rs

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
use rustc_hir::def::DefKind;
22
use rustc_hir::def_id::LocalDefId;
3-
use rustc_middle::query::Providers;
43
use rustc_middle::ty::{self, CratePredicatesMap, GenericArgKind, TyCtxt, Upcast};
54
use rustc_span::Span;
65

@@ -9,11 +8,10 @@ mod explicit;
98
mod implicit_infer;
109
mod utils;
1110

12-
pub(crate) fn provide(providers: &mut Providers) {
13-
*providers = Providers { inferred_outlives_of, inferred_outlives_crate, ..*providers };
14-
}
15-
16-
fn inferred_outlives_of(tcx: TyCtxt<'_>, item_def_id: LocalDefId) -> &[(ty::Clause<'_>, Span)] {
11+
pub(super) fn inferred_outlives_of(
12+
tcx: TyCtxt<'_>,
13+
item_def_id: LocalDefId,
14+
) -> &[(ty::Clause<'_>, Span)] {
1715
match tcx.def_kind(item_def_id) {
1816
DefKind::Struct | DefKind::Enum | DefKind::Union => {
1917
let crate_map = tcx.inferred_outlives_crate(());
@@ -48,7 +46,7 @@ fn inferred_outlives_of(tcx: TyCtxt<'_>, item_def_id: LocalDefId) -> &[(ty::Clau
4846
}
4947
}
5048

51-
fn inferred_outlives_crate(tcx: TyCtxt<'_>, (): ()) -> CratePredicatesMap<'_> {
49+
pub(super) fn inferred_outlives_crate(tcx: TyCtxt<'_>, (): ()) -> CratePredicatesMap<'_> {
5250
// Compute a map from each ADT (struct/enum/union) and lazy type alias to
5351
// the **explicit** outlives predicates (`T: 'a`, `'a: 'b`) that the user wrote.
5452
// Typically there won't be many of these, except in older code where

compiler/rustc_hir_analysis/src/variance/mod.rs

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@ use rustc_arena::DroplessArena;
88
use rustc_hir as hir;
99
use rustc_hir::def::DefKind;
1010
use rustc_hir::def_id::{DefId, LocalDefId};
11-
use rustc_middle::query::Providers;
1211
use rustc_middle::span_bug;
1312
use rustc_middle::ty::{
1413
self, CrateVariancesMap, GenericArgsRef, Ty, TyCtxt, TypeSuperVisitable, TypeVisitable,
@@ -27,18 +26,14 @@ mod solve;
2726

2827
pub(crate) mod dump;
2928

30-
pub(crate) fn provide(providers: &mut Providers) {
31-
*providers = Providers { variances_of, crate_variances, ..*providers };
32-
}
33-
34-
fn crate_variances(tcx: TyCtxt<'_>, (): ()) -> CrateVariancesMap<'_> {
29+
pub(super) fn crate_variances(tcx: TyCtxt<'_>, (): ()) -> CrateVariancesMap<'_> {
3530
let arena = DroplessArena::default();
3631
let terms_cx = terms::determine_parameters_to_be_inferred(tcx, &arena);
3732
let constraints_cx = constraints::add_constraints_from_crate(terms_cx);
3833
solve::solve_constraints(constraints_cx)
3934
}
4035

41-
fn variances_of(tcx: TyCtxt<'_>, item_def_id: LocalDefId) -> &[ty::Variance] {
36+
pub(super) fn variances_of(tcx: TyCtxt<'_>, item_def_id: LocalDefId) -> &[ty::Variance] {
4237
// Skip items with no generics - there's nothing to infer in them.
4338
if tcx.generics_of(item_def_id).is_empty() {
4439
return &[];

compiler/rustc_hir_typeck/src/lib.rs

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -536,7 +536,12 @@ fn fatally_break_rust(tcx: TyCtxt<'_>, span: Span) -> ! {
536536
diag.emit()
537537
}
538538

539+
/// Adds query implementations to the [Providers] vtable, see [`rustc_middle::query`]
539540
pub fn provide(providers: &mut Providers) {
540-
method::provide(providers);
541-
*providers = Providers { typeck, used_trait_imports, ..*providers };
541+
*providers = Providers {
542+
method_autoderef_steps: method::probe::method_autoderef_steps,
543+
typeck,
544+
used_trait_imports,
545+
..*providers
546+
};
542547
}

compiler/rustc_hir_typeck/src/method/mod.rs

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,6 @@ use rustc_hir::def::{CtorOf, DefKind, Namespace};
1313
use rustc_hir::def_id::DefId;
1414
use rustc_infer::infer::{BoundRegionConversionTime, InferOk};
1515
use rustc_infer::traits::PredicateObligations;
16-
use rustc_middle::query::Providers;
1716
use rustc_middle::traits::ObligationCause;
1817
use rustc_middle::ty::{
1918
self, GenericArgs, GenericArgsRef, GenericParamDefKind, Ty, TypeVisitableExt,
@@ -28,10 +27,6 @@ pub(crate) use self::MethodError::*;
2827
use self::probe::{IsSuggestion, ProbeScope};
2928
use crate::FnCtxt;
3029

31-
pub(crate) fn provide(providers: &mut Providers) {
32-
probe::provide(providers);
33-
}
34-
3530
#[derive(Clone, Copy, Debug)]
3631
pub(crate) struct MethodCallee<'tcx> {
3732
/// Impl method ID, for inherent methods, or trait method ID, otherwise.

compiler/rustc_hir_typeck/src/method/probe.rs

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,6 @@ use rustc_infer::infer::canonical::{Canonical, OriginalQueryValues, QueryRespons
1515
use rustc_infer::infer::{BoundRegionConversionTime, DefineOpaqueTypes, InferOk, TyCtxtInferExt};
1616
use rustc_infer::traits::ObligationCauseCode;
1717
use rustc_middle::middle::stability;
18-
use rustc_middle::query::Providers;
1918
use rustc_middle::ty::elaborate::supertrait_def_ids;
2019
use rustc_middle::ty::fast_reject::{DeepRejectCtxt, TreatParams, simplify_type};
2120
use rustc_middle::ty::{
@@ -554,11 +553,7 @@ impl<'a, 'tcx> FnCtxt<'a, 'tcx> {
554553
}
555554
}
556555

557-
pub(crate) fn provide(providers: &mut Providers) {
558-
providers.method_autoderef_steps = method_autoderef_steps;
559-
}
560-
561-
fn method_autoderef_steps<'tcx>(
556+
pub(crate) fn method_autoderef_steps<'tcx>(
562557
tcx: TyCtxt<'tcx>,
563558
goal: CanonicalTyGoal<'tcx>,
564559
) -> MethodAutoderefStepsResult<'tcx> {

0 commit comments

Comments
 (0)