2018-08-30 07:18:55 -05:00
|
|
|
// run-pass
|
2016-07-01 18:11:00 -05:00
|
|
|
fn main() {
|
|
|
|
struct X;
|
|
|
|
trait Foo<T> {
|
|
|
|
fn foo(&self) where (T, Option<T>): Ord {}
|
|
|
|
fn bar(&self, x: &Option<T>) -> bool
|
|
|
|
where Option<T>: Ord { *x < *x }
|
|
|
|
}
|
|
|
|
impl Foo<X> for () {}
|
2019-05-28 13:47:21 -05:00
|
|
|
let _ = &() as &dyn Foo<X>;
|
2016-07-01 18:11:00 -05:00
|
|
|
}
|