pub struct Options {
pub input_version: i32,
pub max_bytes: usize,
pub max_tokens: usize,
pub max_nodes: usize,
pub max_depth: usize,
}Expand description
Source language and resource settings. Hard byte/depth ceilings bound allocation.
Fields§
§input_version: i32Input language weight in decimal thousandths (default 1903).
Exactly 1500 enables the historical sequential fair spelling.
max_bytes: usizeMaximum complete source bytes (hard ceiling: 4 MiB).
max_tokens: usizeMaximum significant tokens (also bounded by bytes).
max_nodes: usizeMaximum statement/declaration/branch nodes.
max_depth: usizeMaximum grammar and expression nesting (hard ceiling: 256).
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Options
impl<'de> Deserialize<'de> for Options
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Forget for Options
impl Freeze for Options
impl Move for Options
impl RefUnwindSafe for Options
impl Send for Options
impl Sync for Options
impl Unpin for Options
impl UnsafeUnpin for Options
impl UnwindSafe for Options
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
Mutably borrows from an owned value. Read more