pub trait ModuleType<'a, C> {
type Error;
// Required method
fn compile_line(
ctx: &mut C,
string: &'a str,
) -> Result<Func<'a>, Self::Error>;
// Provided method
fn compile(
ctx: &mut C,
string: &'a str,
) -> Result<Script<'a>, (usize, Self::Error)> { ... }
}Expand description
Types which implement ModuleType can compile a line into a Func and multiple lines into a
Script
Required Associated Types§
Required Methods§
Provided Methods§
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.