Trait callisp::ast::LispCallable

source ·
pub trait LispCallable: Debug + DynClone {
    fn arity(&self) -> &FunctionArity;
    fn call(
        &self,
        args: Vec<Ast>,
        env: &mut Environment
    ) -> Result<Ast, LispError>; }
Expand description

Trait used to define Lisp functions.

Required Methods§

Return the arity of the function.

Call the function and return the result.

Trait Implementations§

Returns a copy of the value. Read more
Performs copy-assignment from source. Read more

Implementors§