error[E0411]: cannot find type `Self` in this scope --> $DIR/issue-24968.rs:11:11 | 11 | fn foo(_: Self) { | ^^^^ `Self` is only available in traits and impls error: aborting due to previous error