Rollup merge of #130440 - compiler-errors:rpitit-opaque-hidden, r=jieyouxu

Don't ICE in `opaque_hidden_inferred_bound` lint for RPITIT in trait with no default method body

Inline comment should explain the fix.

Fixes #130422
This commit is contained in:
Matthias Krüger 2024-09-17 17:28:34 +02:00 committed by GitHub
commit 02b1776cd3
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 28 additions and 0 deletions

View file

@ -0,0 +1,16 @@
//@ check-pass
// Make sure that the `opaque_hidden_inferred_bound` lint doesn't fire on
// RPITITs with no hidden type.
trait T0 {}
trait T1 {
type A: Send;
}
trait T2 {
fn foo() -> impl T1<A = ((), impl T0)>;
}
fn main() {}