Skip to content

Commit a7171a3

Browse files
committed
Fix the trivial bound problem
1 parent 3a5045a commit a7171a3

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

compiler/rustc_hir_analysis/src/check/wfcheck.rs

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2370,9 +2370,12 @@ impl<'tcx> WfCheckingCtxt<'_, 'tcx> {
23702370
// We lower empty bounds like `Vec<dyn Copy>:` as
23712371
// `WellFormed(Vec<dyn Copy>)`, which will later get checked by
23722372
// regular WF checking
2373-
if let ty::ClauseKind::WellFormed(..) = pred.kind().skip_binder() {
2374-
continue;
2373+
2374+
match pred.kind().skip_binder() {
2375+
ty::ClauseKind::WellFormed(..) | ty::ClauseKind::UnstableFeature(..) => continue,
2376+
_ => {},
23752377
}
2378+
23762379
// Match the existing behavior.
23772380
if pred.is_global() && !pred.has_type_flags(TypeFlags::HAS_BINDER_VARS) {
23782381
let pred = self.normalize(span, None, pred);

0 commit comments

Comments
 (0)