Skip to main content

Eval

Trait Eval 

Source
pub trait Eval {
    type Output;

    // Required method
    fn eval(self, vm: &mut Vm<'_>) -> SourceResult<Self::Output>;
}
Expand description

Evaluate an expression.

Required Associated Types§

Source

type Output

The output of evaluating the expression.

Required Methods§

Source

fn eval(self, vm: &mut Vm<'_>) -> SourceResult<Self::Output>

Evaluate the expression to the output value.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementations on Foreign Types§

Source§

impl Eval for Args<'_>

Source§

type Output = Args

Source§

fn eval(self, vm: &mut Vm<'_>) -> SourceResult<Self::Output>

Source§

impl Eval for Array<'_>

Source§

type Output = Array

Source§

fn eval(self, vm: &mut Vm<'_>) -> SourceResult<Self::Output>

Source§

impl Eval for Auto<'_>

Source§

type Output = Value

Source§

fn eval(self, _: &mut Vm<'_>) -> SourceResult<Self::Output>

Source§

impl Eval for Binary<'_>

Source§

type Output = Value

Source§

fn eval(self, vm: &mut Vm<'_>) -> SourceResult<Self::Output>

Source§

impl Eval for Bool<'_>

Source§

type Output = Value

Source§

fn eval(self, _: &mut Vm<'_>) -> SourceResult<Self::Output>

Source§

impl Eval for Closure<'_>

Source§

type Output = Value

Source§

fn eval(self, vm: &mut Vm<'_>) -> SourceResult<Self::Output>

Source§

impl Eval for Code<'_>

Source§

type Output = Value

Source§

fn eval(self, vm: &mut Vm<'_>) -> SourceResult<Self::Output>

Source§

impl Eval for CodeBlock<'_>

Source§

type Output = Value

Source§

fn eval(self, vm: &mut Vm<'_>) -> SourceResult<Self::Output>

Source§

impl Eval for Conditional<'_>

Source§

type Output = Value

Source§

fn eval(self, vm: &mut Vm<'_>) -> SourceResult<Self::Output>

Source§

impl Eval for ContentBlock<'_>

Source§

type Output = Content

Source§

fn eval(self, vm: &mut Vm<'_>) -> SourceResult<Self::Output>

Source§

impl Eval for Contextual<'_>

Source§

type Output = Content

Source§

fn eval(self, vm: &mut Vm<'_>) -> SourceResult<Self::Output>

Source§

impl Eval for DestructAssignment<'_>

Source§

type Output = Value

Source§

fn eval(self, vm: &mut Vm<'_>) -> SourceResult<Self::Output>

Source§

impl Eval for Dict<'_>

Source§

type Output = Dict

Source§

fn eval(self, vm: &mut Vm<'_>) -> SourceResult<Self::Output>

Source§

impl Eval for Emph<'_>

Source§

type Output = Content

Source§

fn eval(self, vm: &mut Vm<'_>) -> SourceResult<Self::Output>

Source§

impl Eval for EnumItem<'_>

Source§

type Output = Content

Source§

fn eval(self, vm: &mut Vm<'_>) -> SourceResult<Self::Output>

Source§

impl Eval for Equation<'_>

Source§

type Output = Content

Source§

fn eval(self, vm: &mut Vm<'_>) -> SourceResult<Self::Output>

Source§

impl Eval for Escape<'_>

Source§

type Output = Value

Source§

fn eval(self, _: &mut Vm<'_>) -> SourceResult<Self::Output>

Source§

impl Eval for Expr<'_>

Source§

type Output = Value

Source§

fn eval(self, vm: &mut Vm<'_>) -> SourceResult<Self::Output>

Source§

impl Eval for FieldAccess<'_>

Source§

type Output = Value

Source§

fn eval(self, vm: &mut Vm<'_>) -> SourceResult<Self::Output>

Source§

impl Eval for Float<'_>

Source§

type Output = Value

Source§

fn eval(self, _: &mut Vm<'_>) -> SourceResult<Self::Output>

Source§

impl Eval for ForLoop<'_>

Source§

type Output = Value

Source§

fn eval(self, vm: &mut Vm<'_>) -> SourceResult<Self::Output>

Source§

impl Eval for FuncCall<'_>

Source§

type Output = Value

Source§

fn eval(self, vm: &mut Vm<'_>) -> SourceResult<Self::Output>

Source§

impl Eval for FuncReturn<'_>

Source§

type Output = Value

Source§

fn eval(self, vm: &mut Vm<'_>) -> SourceResult<Self::Output>

Source§

impl Eval for Heading<'_>

Source§

type Output = Content

Source§

fn eval(self, vm: &mut Vm<'_>) -> SourceResult<Self::Output>

Source§

impl Eval for Ident<'_>

Source§

type Output = Value

Source§

fn eval(self, vm: &mut Vm<'_>) -> SourceResult<Self::Output>

Source§

impl Eval for Int<'_>

Source§

type Output = Value

Source§

fn eval(self, _: &mut Vm<'_>) -> SourceResult<Self::Output>

Source§

impl Eval for Label<'_>

Source§

type Output = Value

Source§

fn eval(self, _: &mut Vm<'_>) -> SourceResult<Self::Output>

Source§

impl Eval for LetBinding<'_>

Source§

type Output = Value

Source§

fn eval(self, vm: &mut Vm<'_>) -> SourceResult<Self::Output>

Source§

impl Eval for Linebreak<'_>

Source§

type Output = Content

Source§

fn eval(self, _: &mut Vm<'_>) -> SourceResult<Self::Output>

Source§

impl Eval for Link<'_>

Source§

type Output = Content

Source§

fn eval(self, _: &mut Vm<'_>) -> SourceResult<Self::Output>

Source§

impl Eval for ListItem<'_>

Source§

type Output = Content

Source§

fn eval(self, vm: &mut Vm<'_>) -> SourceResult<Self::Output>

Source§

impl Eval for LoopBreak<'_>

Source§

type Output = Value

Source§

fn eval(self, vm: &mut Vm<'_>) -> SourceResult<Self::Output>

Source§

impl Eval for LoopContinue<'_>

Source§

type Output = Value

Source§

fn eval(self, vm: &mut Vm<'_>) -> SourceResult<Self::Output>

Source§

impl Eval for Markup<'_>

Source§

type Output = Content

Source§

fn eval(self, vm: &mut Vm<'_>) -> SourceResult<Self::Output>

Source§

impl Eval for Math<'_>

Source§

type Output = Content

Source§

fn eval(self, vm: &mut Vm<'_>) -> SourceResult<Self::Output>

Source§

impl Eval for MathAccess<'_>

Source§

type Output = Value

Source§

fn eval(self, vm: &mut Vm<'_>) -> SourceResult<Self::Output>

Source§

impl Eval for MathAlignPoint<'_>

Source§

type Output = Content

Source§

fn eval(self, _: &mut Vm<'_>) -> SourceResult<Self::Output>

Source§

impl Eval for MathArgs<'_>

Source§

type Output = Args

Source§

fn eval(self, vm: &mut Vm<'_>) -> SourceResult<Self::Output>

Source§

impl Eval for MathAttach<'_>

Source§

type Output = Content

Source§

fn eval(self, vm: &mut Vm<'_>) -> SourceResult<Self::Output>

Source§

impl Eval for MathCall<'_>

Source§

type Output = Value

Source§

fn eval(self, vm: &mut Vm<'_>) -> SourceResult<Self::Output>

Source§

impl Eval for MathDelimited<'_>

Source§

type Output = Content

Source§

fn eval(self, vm: &mut Vm<'_>) -> SourceResult<Self::Output>

Source§

impl Eval for MathFieldAccess<'_>

Source§

type Output = Value

Source§

fn eval(self, vm: &mut Vm<'_>) -> SourceResult<Self::Output>

Source§

impl Eval for MathFrac<'_>

Source§

type Output = Content

Source§

fn eval(self, vm: &mut Vm<'_>) -> SourceResult<Self::Output>

Source§

impl Eval for MathIdent<'_>

Source§

type Output = Value

Source§

fn eval(self, vm: &mut Vm<'_>) -> SourceResult<Self::Output>

Source§

impl Eval for MathPrimes<'_>

Source§

type Output = Content

Source§

fn eval(self, _: &mut Vm<'_>) -> SourceResult<Self::Output>

Source§

impl Eval for MathRoot<'_>

Source§

type Output = Content

Source§

fn eval(self, vm: &mut Vm<'_>) -> SourceResult<Self::Output>

Source§

impl Eval for MathShorthand<'_>

Source§

type Output = Value

Source§

fn eval(self, _: &mut Vm<'_>) -> SourceResult<Self::Output>

Source§

impl Eval for MathText<'_>

Source§

type Output = Content

Source§

fn eval(self, _: &mut Vm<'_>) -> SourceResult<Self::Output>

Source§

impl Eval for ModuleImport<'_>

Source§

type Output = Value

Source§

fn eval(self, vm: &mut Vm<'_>) -> SourceResult<Self::Output>

Source§

impl Eval for ModuleInclude<'_>

Source§

type Output = Content

Source§

fn eval(self, vm: &mut Vm<'_>) -> SourceResult<Self::Output>

Source§

impl Eval for None<'_>

Source§

type Output = Value

Source§

fn eval(self, _: &mut Vm<'_>) -> SourceResult<Self::Output>

Source§

impl Eval for Numeric<'_>

Source§

type Output = Value

Source§

fn eval(self, _: &mut Vm<'_>) -> SourceResult<Self::Output>

Source§

impl Eval for Parbreak<'_>

Source§

type Output = Content

Source§

fn eval(self, _: &mut Vm<'_>) -> SourceResult<Self::Output>

Source§

impl Eval for Parenthesized<'_>

Source§

type Output = Value

Source§

fn eval(self, vm: &mut Vm<'_>) -> SourceResult<Self::Output>

Source§

impl Eval for Raw<'_>

Source§

type Output = Content

Source§

fn eval(self, _: &mut Vm<'_>) -> SourceResult<Self::Output>

Source§

impl Eval for Ref<'_>

Source§

type Output = Content

Source§

fn eval(self, vm: &mut Vm<'_>) -> SourceResult<Self::Output>

Source§

impl Eval for SetRule<'_>

Source§

type Output = Styles

Source§

fn eval(self, vm: &mut Vm<'_>) -> SourceResult<Self::Output>

Source§

impl Eval for Shorthand<'_>

Source§

type Output = Value

Source§

fn eval(self, _: &mut Vm<'_>) -> SourceResult<Self::Output>

Source§

impl Eval for ShowRule<'_>

Source§

type Output = Recipe

Source§

fn eval(self, vm: &mut Vm<'_>) -> SourceResult<Self::Output>

Source§

impl Eval for SmartQuote<'_>

Source§

type Output = Content

Source§

fn eval(self, _: &mut Vm<'_>) -> SourceResult<Self::Output>

Source§

impl Eval for Space<'_>

Source§

type Output = Content

Source§

fn eval(self, _: &mut Vm<'_>) -> SourceResult<Self::Output>

Source§

impl Eval for Str<'_>

Source§

type Output = Value

Source§

fn eval(self, _: &mut Vm<'_>) -> SourceResult<Self::Output>

Source§

impl Eval for Strong<'_>

Source§

type Output = Content

Source§

fn eval(self, vm: &mut Vm<'_>) -> SourceResult<Self::Output>

Source§

impl Eval for TermItem<'_>

Source§

type Output = Content

Source§

fn eval(self, vm: &mut Vm<'_>) -> SourceResult<Self::Output>

Source§

impl Eval for Text<'_>

Source§

type Output = Content

Source§

fn eval(self, _: &mut Vm<'_>) -> SourceResult<Self::Output>

Source§

impl Eval for Unary<'_>

Source§

type Output = Value

Source§

fn eval(self, vm: &mut Vm<'_>) -> SourceResult<Self::Output>

Source§

impl Eval for WhileLoop<'_>

Source§

type Output = Value

Source§

fn eval(self, vm: &mut Vm<'_>) -> SourceResult<Self::Output>

Implementors§