macro_rules! impl_from_for_primitive { ($this:ty; from $from:ty $(,)?) => { ... }; }
Implement From for a primitive.
From
With a newtype struct:
use impl_more::impl_from_for_primitive; struct Checked(bool); impl_from_for_primitive!(bool; from Checked); let foo = bool::from(Checked(true));