pub trait ConstFromStr: Sized {
// Required method
fn const_from_str(s: &str) -> Option<Self>;
}Expand description
Types that can be converted from a &'static str at compile-time.
Used for compile-time validation of #[codec(tag_as = ...)] tags.
Required Methods§
fn const_from_str(s: &str) -> Option<Self>
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".