Trait oftlisp::Context [] [src]

pub trait Context: Sized {
    type BuiltinFunction: Clone + Debug + Finalize + Trace;
    type Expr: Clone + Debug + Finalize + Trace;
    type ObjectVtable: Clone + Debug + Finalize + Trace;
    type UserFunction: Clone + Debug + Finalize + Trace;
    type ValueMeta: Clone + Debug + Default + Finalize + Trace;
    fn from_expr(expr: Gc<Expr<Self>>) -> Gc<Self::Expr>;
}

A trait for the things a Value is parameterized over.

Yeah, it's vague. Basically, think of it as a collection of associated types that is used to define Value.

Associated Types

The type of a function implemented by the runtime.

The type of an expression in the AST.

The type of the vtable of an object.

The type of a user function. This probably should just be the arguments (as an Args<C>), the body (as C::Expr), and the variables closed over and their values (as a GcLinkedList<(Symbol, Value<C>)>).

The metadata attached to the value.

Required Methods

Converts a standard ast::Expr to the expression type of the context.

Implementors