rust/tests/ui/impl-trait/issues/issue-77987.rs
2024-02-16 20:02:50 +00:00

22 lines
254 B
Rust

#![feature(type_alias_impl_trait)]
//@ check-pass
trait Foo<T> {}
impl<T, U> Foo<T> for U {}
type Scope = impl Foo<()>;
#[allow(unused)]
fn infer_scope() -> Scope {
()
}
#[allow(unused)]
fn ice() -> impl Foo<Scope>
{
loop {}
}
fn main() {}