|
runtime 1.1.4
Checked CEL programs, owned values, and reusable execution stacks
|
Build checked operations with cel::dyn_segment, freeze them as cel::compiled_segment, and bind typed repeated calls with cel::prepared_segment. See Compile and reuse a program and Add types and operations for examples.
Classes | |
| struct | cel::stack_origin |
| A byte cursor and live-slot depth below a fragment's local operands. More... | |
| class | cel::prepared_segment< R, Args > |
| A move-only typed binding that borrows inputs and returns concrete results. More... | |
| struct | cel::stack_reservation |
| Total byte and slot capacities for one prefixed execution. More... | |
| struct | cel::stack_requirements |
| The statically known storage requirements of a frozen ordinary program. More... | |
| class | cel::dyn_segment |
| A move-only builder of checked, source-ordered operations. More... | |
| class | cel::compiled_segment |
| A move-only handle to immutable frozen code and its captures. More... | |
Functions | |
| bool | cel::operator== (const stack_origin &left, const stack_origin &right) noexcept |
| Compares both ambient coordinates exactly. | |
| template<class Signature, class F> requires (detail::signature_binding<Signature, std::decay_t<F>>::available) | |
| auto | cel::with_signature (F &&callback) |
| Selects an exact const callback member from an ambiguous or uninspectable overload set. | |
| template<class R, class... Args> | |
| prepared_segment< R, Args... > | cel::compiled_segment::prepare () const |
| Binds exact recursive concrete adapters once, admitting valid client leaves at roots. | |
|
inlinenoexcept |
Compares both ambient coordinates exactly.
Example: stack_origin{} == stack_origin{0, 0}.
| prepared_segment< R, Args... > cel::compiled_segment::prepare | ( | ) | const |
Binds exact recursive concrete adapters once, admitting valid client leaves at roots.
R must not be void; use std::tuple<> for a source-unit result. Unused declared arguments are accepted and are not converted during calls.
Throws std::invalid_argument for incompatible argument/result shapes, undeclared reads, or a dependent origin; std::logic_error for a moved-from handle.
Complexity: O(arity + adapter construction + complete type-comparison work) time and argument binding storage, plus adapter result storage and comparison auxiliary space.
Example: auto bound = program.prepare<double, double>();.
| auto cel::with_signature | ( | F && | callback | ) |
Selects an exact const callback member from an ambiguous or uninspectable overload set.
Signature includes actual parameter and return reference qualifiers; no conversion creates a signature that the callback does not declare. The wrapper owns F normally. Generic callbacks that cannot prove their instantiated parameter identities use this explicit selection. Function pointers can instead be supplied directly with an exact cast.
Complexity: the callback's construction time and owned capture storage.
Example: builder.op1<double, double>(with_signature<double(double)>(overloaded{}));.