update TypeFlags
to deal with missing ct substs
This commit is contained in:
parent
b1786f62ed
commit
afd892a549
2 changed files with 2 additions and 2 deletions
|
@ -117,7 +117,7 @@ impl<'tcx> LateLintPass<'tcx> for NeedlessPassByValue {
|
||||||
let fn_def_id = cx.tcx.hir().local_def_id(hir_id);
|
let fn_def_id = cx.tcx.hir().local_def_id(hir_id);
|
||||||
|
|
||||||
let preds = traits::elaborate_predicates(cx.tcx, cx.param_env.caller_bounds().iter())
|
let preds = traits::elaborate_predicates(cx.tcx, cx.param_env.caller_bounds().iter())
|
||||||
.filter(|p| !p.is_global())
|
.filter(|p| !p.is_global(cx.tcx))
|
||||||
.filter_map(|obligation| {
|
.filter_map(|obligation| {
|
||||||
// Note that we do not want to deal with qualified predicates here.
|
// Note that we do not want to deal with qualified predicates here.
|
||||||
match obligation.predicate.kind().no_bound_vars() {
|
match obligation.predicate.kind().no_bound_vars() {
|
||||||
|
|
|
@ -1581,7 +1581,7 @@ pub fn fn_has_unsatisfiable_preds(cx: &LateContext<'_>, did: DefId) -> bool {
|
||||||
.predicates_of(did)
|
.predicates_of(did)
|
||||||
.predicates
|
.predicates
|
||||||
.iter()
|
.iter()
|
||||||
.filter_map(|(p, _)| if p.is_global() { Some(*p) } else { None });
|
.filter_map(|(p, _)| if p.is_global(cx.tcx) { Some(*p) } else { None });
|
||||||
traits::impossible_predicates(
|
traits::impossible_predicates(
|
||||||
cx.tcx,
|
cx.tcx,
|
||||||
traits::elaborate_predicates(cx.tcx, predicates)
|
traits::elaborate_predicates(cx.tcx, predicates)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue