pub struct EvaluatorOptions {
pub timeout_ms: Option<u64>,
pub max_stack_depth: Option<usize>,
pub max_sequence_length: Option<usize>,
}Expand description
Resource-limit guardrails, mirroring jsonata-js 2.2.1’s timeout/stack/sequence
evaluator options. All fields default to None = unlimited (current behavior).
Fields§
§timeout_ms: Option<u64>Maximum wall-clock evaluation time in milliseconds. Exceeding it raises D1012.
max_stack_depth: Option<usize>Maximum AST-recursion stack depth. Exceeding it raises D1011 if this is the tighter of this value and the hardcoded native-stack safety ceiling (302); otherwise the hardcoded ceiling still raises U1001 (see GitHub issue #34).
max_sequence_length: Option<usize>Maximum length of a query-result sequence (map/filter/wildcard/descendants/
keys/lookup/append/spread/each/range/path-mapping). Exceeding it raises D2015.
Does NOT currently apply to literal array construction (MakeArray/
ArrayConstruct) — NOTE this is a deliberate, temporary divergence from
upstream, not a match: jsonata-js DOES cap flat/non-nested array literals
(via fn.append’s createSequence hook in evaluateUnary’s [ case).
Deferred until the separate MakeArray(u16) truncation bug is fixed (see
the design spec’s “Sequence length → D2015” section).
Trait Implementations§
Source§impl Clone for EvaluatorOptions
impl Clone for EvaluatorOptions
Source§fn clone(&self) -> EvaluatorOptions
fn clone(&self) -> EvaluatorOptions
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more