Skip to main content

Module error

Module error 

Source
Expand description

Error type returned by the parser and the interpreter.

Every fallible API in this crate returns Result<T, ShapeError>. Variants cover three broad failure classes:

  • Parse failuresParseError carries a human-readable message from the nom parser, including the offending input span.
  • Numeric / structural validationInvalidNumericValue, EmptySplit, InvalidFloatingSize, SplitOverflow, NoFloatingSlots, UnknownCompSelector, OffsetTooLarge, InvalidRoofAngle, InvalidAlignTarget are raised when a parsed grammar would produce geometry that isn’t well-defined.
  • DoS safety capsCapacityOverflow and DepthLimitExceeded are returned when a grammar exceeds the engine’s bounded queue, terminal, op-count, identifier, or recursion limits rather than allowing unbounded resource use.

Enums§

ShapeError
All errors produced by the parser and the interpreter.