blob: 468dc89a73e61d55e549d3d4842c4e4c52fc0428 [file] [log] [blame]
//@ check-pass
// Regression test for #57276.
// Make sure that object safety checking doesn't freak out when
// we have impossible-to-satisfy `DispatchFromDyn` predicates.
#![feature(arbitrary_self_types, dispatch_from_dyn)]
use std::ops::{Deref, DispatchFromDyn};
trait Trait<T: Deref<Target = Self> + DispatchFromDyn<T>> {
fn foo(self: T) -> dyn Trait<T>;
}
fn main() {}