Rename hook.
This commit is contained in:
parent
a2e151ca4b
commit
3a55c283d0
5 changed files with 6 additions and 6 deletions
|
@ -72,7 +72,7 @@ pub(crate) fn eval_to_valtree<'tcx>(
|
|||
}
|
||||
|
||||
#[instrument(skip(tcx), level = "debug")]
|
||||
pub(crate) fn try_destructure_mir_constant_for_diagnostics<'tcx>(
|
||||
pub(crate) fn try_destructure_mir_constant_for_user_output<'tcx>(
|
||||
tcx: TyCtxtAt<'tcx>,
|
||||
val: mir::ConstValue<'tcx>,
|
||||
ty: Ty<'tcx>,
|
||||
|
|
|
@ -54,8 +54,8 @@ pub fn provide(providers: &mut Providers) {
|
|||
let (param_env, raw) = param_env_and_value.into_parts();
|
||||
const_eval::eval_to_valtree(tcx, param_env, raw)
|
||||
};
|
||||
providers.hooks.try_destructure_mir_constant_for_diagnostics =
|
||||
const_eval::try_destructure_mir_constant_for_diagnostics;
|
||||
providers.hooks.try_destructure_mir_constant_for_user_output =
|
||||
const_eval::try_destructure_mir_constant_for_user_output;
|
||||
providers.valtree_to_const_val = |tcx, (ty, valtree)| {
|
||||
const_eval::valtree_to_const_value(tcx, ty::ParamEnv::empty().and(ty), valtree)
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue