pub trait TmIndex: Copy {
// Required method
fn tm_index(self) -> usize;
}Expand description
Discriminant-to-index conversion for the two parallel TagMethod enums.
Both lua_types::tagmethod::TagMethod and crate::tagmethods::TagMethod
are #[repr(u8)] with the same ORDER TM layout, so casting through u8
yields the correct GlobalState.tmname index for either type.
Required Methods§
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".