pub const MAX_NESTING_DEPTH: usize = 64;Expand description
Recursive-descent parser for ISO 10303-21 (Part 21) files.
Consumes self on Parser::parse because the underlying Lexer is
a one-pass iterator and cannot be rewound.
Maximum parameter nesting depth. In practice STEP parameters nest only a few
levels (nested LIST OF LIST, typed-wrapped measures); this bound of 64 is a
large margin over any realistic file yet small enough that the
recursive-descent frames stay well within a thread’s stack (a debug build
spans several frames per nesting level). It turns adversarially deep
(((…))) input into a graceful Error::NestingTooDeep instead of a
stack-overflow abort.