Closed
Description
There's an inconsistency when initializing tuple structs as associated constants with Self
:
struct Foo(i32);
impl Foo {
const A: Self = Self(1); // Fails with "did you mean `Self { /* fields */ }`?"
const B: Self = Self { 0: 2 }; // succeeds
}
I'd expect Self(1)
to work if Self { 0: 2 }
works.
Metadata
Metadata
Assignees
Labels
No labels