Module arena_ctx

Module arena_ctx 

Source
Expand description

Arena context for AST allocation.

This module provides AstContext, a collection of typed arenas used during parsing to allocate AST nodes. All nodes are bump-allocated for efficiency, with the 'a lifetime tracking the arena’s scope.

The context contains separate arenas for:

  • Logical expressions (LogicExpr)
  • Terms (Term)
  • Noun phrases (NounPhrase)
  • Symbols, thematic roles, and prepositional phrases
  • Imperative statements (optional, for LOGOS mode)

Structs§

AstContext
Collection of typed arenas for AST allocation during parsing.