pub struct ExecutionBounds {
pub max_call_depth: usize,
pub max_steps: Option<usize>,
}Expand description
How much a blue program may do before it is refused: nested calls and evaluation steps.
Both are BOUNDS in the sense blue-lang-cli’s config module admits: a
terminating program under bounds above its cost returns the same value, and
one that exceeds either is refused with a catchable depth-exceeded or
fuel-exhausted error naming the limit and the function — never a process
abort, which is what exceeding the host stack was before tatara-lisp-eval
0.3.63. The walker and the VM run under the same bounds and refuse with the
same message.
Fields§
§max_call_depth: usizeNested (non-tail) calls alive at once. Tail calls do not count.
max_steps: Option<usize>Evaluation steps per run; None is unbounded.
Implementations§
Source§impl ExecutionBounds
impl ExecutionBounds
Sourcepub const DEFAULT: Self
pub const DEFAULT: Self
Depth at tatara-lisp-eval’s DEFAULT_MAX_DEPTH, steps unbounded.
The two defaults differ for one reason: whether a program that works
today keeps working. A recursion past 100k frames never worked — it
aborted the process — so bounding depth removes no behaviour. A run
longer than any finite step count did work (simulations, tools on
nodes), so a default step bound would remove it; for a few hours of
2026-09-29 blue shipped 50M (~3 s) and did exactly that. A host that
runs code it did not write, or a test that must see a runaway end,
sets max_steps itself.
Trait Implementations§
Source§impl Clone for ExecutionBounds
impl Clone for ExecutionBounds
impl Copy for ExecutionBounds
Source§impl Debug for ExecutionBounds
impl Debug for ExecutionBounds
impl Eq for ExecutionBounds
Source§impl PartialEq for ExecutionBounds
impl PartialEq for ExecutionBounds
impl StructuralPartialEq for ExecutionBounds
Auto Trait Implementations§
impl Freeze for ExecutionBounds
impl RefUnwindSafe for ExecutionBounds
impl Send for ExecutionBounds
impl Sync for ExecutionBounds
impl Unpin for ExecutionBounds
impl UnsafeUnpin for ExecutionBounds
impl UnwindSafe for ExecutionBounds
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.