blob: b48a5bb16e973df1e6e86cd4e0d826db70f22bcf [file] [log] [blame] [edit]
//@ edition:2015
// Regression test for <github.com/rust-lang/rust/issues/145185>.
mod module {
pub trait Trait {
fn method(&self);
}
}
// Note that we do not import Trait
use std::ops::Deref;
fn foo(x: impl Deref<Target: module::Trait>) {
x.method();
//~^ ERROR no method named `method` found for type parameter
}
fn main() {}