diff options
Diffstat (limited to '')
-rw-r--r-- | src/test/ui/issues/auxiliary/issue-18501.rs | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/src/test/ui/issues/auxiliary/issue-18501.rs b/src/test/ui/issues/auxiliary/issue-18501.rs new file mode 100644 index 000000000..dd914b464 --- /dev/null +++ b/src/test/ui/issues/auxiliary/issue-18501.rs @@ -0,0 +1,17 @@ +#![crate_type = "rlib"] +struct Foo; + +trait Tr { + fn tr(&self); +} + +impl Tr for Foo { + fn tr(&self) {} +} + +fn take_method<T>(f: fn(&T), t: &T) {} + +#[inline] +pub fn pass_method() { + take_method(Tr::tr, &Foo); +} |