mirror of
https://github.com/rust-lang/rust.git
synced 2024-12-02 03:33:59 +00:00
18 lines
318 B
Rust
18 lines
318 B
Rust
//@ check-pass
|
|
//@ compile-flags: -Znext-solver
|
|
|
|
trait Local {}
|
|
|
|
trait Overlap { fn f(); }
|
|
impl<T> Overlap for Option<T> where Self: Clone, { fn f() {} }
|
|
impl<T> Overlap for Option<T> where Self: Local, { fn f() {} }
|
|
|
|
fn test<T>()
|
|
where
|
|
Option<T>: Clone + Local,
|
|
{
|
|
<Option<T> as Overlap>::f();
|
|
}
|
|
|
|
fn main() {}
|