Expand description
Error recovery strategies and traits for the Perl parser. Error recovery for the Perl parser
This module implements error recovery strategies to continue parsing even when syntax errors are encountered. This is essential for IDE scenarios where code is often incomplete or temporarily invalid.
§Progress Invariant
All recovery operations guarantee forward progress: every recovery attempt must consume at least one token or exit. This prevents infinite loops when the parser cannot make sense of the input.
§Budget Awareness
Recovery operations respect the ParseBudget limits to prevent runaway
parsing on adversarial input. When budget is exhausted, recovery returns
immediately with an appropriate error node.
Structs§
- Parse
Error - Error information with recovery context for comprehensive Perl parsing error handling.
Enums§
- Recovery
Result - Result of a recovery operation.
- Sync
Point - Synchronization tokens for error recovery
Traits§
- Error
Recovery - Error recovery strategies
- Parser
Error Recovery - Parser extensions for error recovery
- Statement
Recovery - Recovery-aware statement parsing