Skip to main content

Crate sim_lib_function

Crate sim_lib_function 

Source
Expand description

Language-neutral immutable function plans.

A FunctionPlan records declaration metadata only. It deliberately has no evaluation or invocation surface; later instance machinery composes a plan with a concrete guest policy.

A body remains a statically selected guest policy. Type erasure cannot meet the bound of the future instance type:

use std::any::Any;

trait GuestBodyPolicy {}
struct FunctionInstance<B: GuestBodyPolicy>(B);

fn erase(body: Box<dyn Any>) -> FunctionInstance<Box<dyn Any>> {
    FunctionInstance(body)
}

Structs§

BoundArgument
An input paired with its exact origin.
BoundCall
A stable, lossless call record awaiting guest-policy decisions.
BrowseProjection
Canonical, inert projection of a function’s browsable Shape metadata.
CallInput
Mutable call input assembled by kernel and guest adapters.
CallMode
The ways in which a caller may address a parameter.
CaptureDescriptor
Stable metadata for one lexical capture slot.
CapturedBinding
One shared binding cell paired with its identity in the managed graph.
FunctionInstance
A language-neutral, managed function object with a concrete guest body.
FunctionPlan
Immutable declaration metadata shared by guest function implementations.
ParameterDescriptor
Stable declaration metadata for one parameter.
PlanError
A construction failure for an immutable function plan.

Enums§

ArgumentInput
One undecided input supplied to the neutral adaptation boundary.
ArgumentOrigin
The exact place at which an argument entered the call boundary.
InstanceError
Failure to construct a managed function instance.
ParameterKind
The declaration role of a parameter.

Traits§

FunctionBodyPolicy
Guest-owned execution policy for one concrete function body type.

Functions§

bind
Freezes an assembled input stream without applying a language rule.
dispatch_method_body
Projects a function instance into a dispatch method body.
validate_capture_bindings
Validates that concrete capture cells exactly match every frozen plan slot.