kei-lisp - v3.0.1
    Preparing search index...

    Type Alias PluginContext

    Context passed to a plugin's apply call. Holds the live interpreter state needed to perform recursive evaluation or to read / write the environment.

    type PluginContext = {
        depth: number;
        environment: Table;
        streamManager: StreamManager;
        eval(form: LispValue): LispValue;
    }
    Index
    depth: number

    The current call depth (used for spy indentation).

    environment: Table

    The current variable binding environment.

    streamManager: StreamManager

    The stream manager that owns the interpreter's I/O / spy / trace streams.

    • Re-evaluates the given form using the current environment / stream manager / depth. Use this to evaluate a sub-form (e.g. when the plugin received a lambda value).

      Parameters

      Returns LispValue

      the evaluation result