pub trait FromLua: Sized {
const TYPE_NAME: &'static str = core::any::type_name::();
fn from_lua(s: &State, i: Index) -> Option<Self>;
fn check(s: &State, i: Index) -> Self { ... }
} Expand description
Trait for types that can be taken from the Lua stack.
It is important that implementors of this trait ensure that from_lua
behaves like one of the lua_to* functions for consistency.