You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Of course, Foo could not impl From<Variants> unless all the inner data implemented Default, and even then it might be preferable to have a more explicit impl Variants { pub fn as_foo_with_defaults(self) -> Foo { ... } }.
The text was updated successfully, but these errors were encountered:
It would be nice to be able to extract just the variants from an enum as a sub-enum, ignoring tuple-like or struct-like data. So this:
...would generate something like this:
Of course,
Foo
could not implFrom<Variants>
unless all the inner data implementedDefault
, and even then it might be preferable to have a more explicitimpl Variants { pub fn as_foo_with_defaults(self) -> Foo { ... } }
.The text was updated successfully, but these errors were encountered: