mirror of
https://github.com/rust-lang/rust-clippy
synced 2024-11-10 15:14:29 +00:00
update const_eval_resolve
This commit is contained in:
parent
2c4570c958
commit
731c98b16b
2 changed files with 14 additions and 4 deletions
|
@ -181,7 +181,15 @@ fn is_value_unfrozen_expr<'tcx>(cx: &LateContext<'tcx>, hir_id: HirId, def_id: D
|
|||
|
||||
let result = cx
|
||||
.tcx
|
||||
.const_eval_resolve(cx.param_env, ty::WithOptConstParam::unknown(def_id), substs, None, None);
|
||||
.const_eval_resolve(
|
||||
cx.param_env,
|
||||
ty::Unevaluated {
|
||||
def: ty::WithOptConstParam::unknown(def_id),
|
||||
substs,
|
||||
promoted: None
|
||||
},
|
||||
None
|
||||
);
|
||||
is_value_unfrozen_raw(cx, result, ty)
|
||||
}
|
||||
|
||||
|
|
|
@ -341,9 +341,11 @@ impl<'a, 'tcx> ConstEvalLateContext<'a, 'tcx> {
|
|||
.tcx
|
||||
.const_eval_resolve(
|
||||
self.param_env,
|
||||
ty::WithOptConstParam::unknown(def_id),
|
||||
substs,
|
||||
None,
|
||||
ty::Unevaluated {
|
||||
def: ty::WithOptConstParam::unknown(def_id),
|
||||
substs,
|
||||
promoted: None,
|
||||
},
|
||||
None,
|
||||
)
|
||||
.ok()
|
||||
|
|
Loading…
Reference in a new issue