041e54bd92
Fix #80476.
15 lines
341 B
Rust
15 lines
341 B
Rust
trait Lam {}
|
|
|
|
pub struct B;
|
|
impl Lam for B {}
|
|
pub struct Wrap<T>(T);
|
|
|
|
const _A: impl Lam = {
|
|
//~^ `impl Trait` only allowed in function and inherent method argument and return types
|
|
let x: Wrap<impl Lam> = Wrap(B);
|
|
//~^ `impl Trait` only allowed in function and inherent method argument and return types
|
|
x.0
|
|
};
|
|
|
|
fn main() {}
|