[][src]Struct libslide::partial_evaluator::variable_expand::EagerVariableExpander

struct EagerVariableExpander<'a> {
    expr: RcExpr,
    expand_def: Option<&'a Assignment>,
}

Eagerly expands variables in an expression.

An EagerVariableExpander expands all matching variables on every call to expand.

For example, "a + b".expand("a = b + 1").expand("b = c") would expand to "c + 1 + c". Compare this to a LazyVariableExpander.

Note, however, that an EagerVariableExpander will not try to expand variables within an expanded variable definition on the same call to expand.

For example, "a".expand("a = a + a") would expand to "a + a" rather than "a + a + a + a + ...".

Fields

expr: RcExprexpand_def: Option<&'a Assignment>

Trait Implementations

impl<'a> ExpressionTransformer<'a> for EagerVariableExpander<'a>[src]

impl<'a> VariableExpander<'a> for EagerVariableExpander<'a>[src]

Auto Trait Implementations

impl<'a> RefUnwindSafe for EagerVariableExpander<'a>

impl<'a> Send for EagerVariableExpander<'a>

impl<'a> Sync for EagerVariableExpander<'a>

impl<'a> Unpin for EagerVariableExpander<'a>

impl<'a> UnwindSafe for EagerVariableExpander<'a>

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.