error: non-defining opaque type use in defining scope --> $DIR/generic_nondefining_use.rs:17:21 | LL | fn concrete_ty() -> OneTy { | ^^^^^^^^^^ | note: used non-generic type `u32` for generic parameter --> $DIR/generic_nondefining_use.rs:11:12 | LL | type OneTy = impl Debug; | ^ error: non-defining opaque type use in defining scope --> $DIR/generic_nondefining_use.rs:22:27 | LL | type OneLifetime<'a> = impl Debug; | -- cannot use static lifetime; use a bound lifetime instead or remove the lifetime parameter from the opaque type ... LL | fn concrete_lifetime() -> OneLifetime<'static> { | ^^^^^^^^^^^^^^^^^^^^ error: non-defining opaque type use in defining scope --> $DIR/generic_nondefining_use.rs:27:24 | LL | fn concrete_const() -> OneConst<{123}> { | ^^^^^^^^^^^^^^^ | note: used non-generic constant `{123}` for generic parameter --> $DIR/generic_nondefining_use.rs:13:21 | LL | type OneConst = impl Debug; | ^ error: aborting due to 3 previous errors