halotukozak.alpaca.internal.parser
Members list
Type members
Classlikes
Base class for parsers.
Base class for parsers.
Users should extend this class and define their grammar rules as Rule instances. The parser uses an LR parsing algorithm with automatic parse table generation.
Type parameters
- Ctx
-
the parser context type;
Parserwithout a type argument uses ParserCtx.Empty
Attributes
- Source
- Parser.scala
- Supertypes
-
class Objecttrait Matchableclass Any
A production with its semantic action, which a runtime ParseAction.Reduction reduces by. There is one per production, shared by every cell of the parse table that reduces by it.
A production with its semantic action, which a runtime ParseAction.Reduction reduces by. There is one per production, shared by every cell of the parse table that reduces by it.
Type parameters
- Ctx
-
the parser context type
Attributes
- Source
- ProductionRule.scala
- Supertypes
-
class Objecttrait Matchableclass Any
The parse table as the parser runs it, built by the code ParseTable.toRuntime generates.
The parse table as the parser runs it, built by the code ParseTable.toRuntime generates.
Type parameters
- Ctx
-
the parser context type
Value parameters
- rows
-
one per state (dense, consecutive, starting at 0), each a symbol -> action map
Attributes
- Source
- RuntimeTable.scala
- Supertypes
-
class Objecttrait Matchableclass Any
Attributes
- Source
- createTables.scala
- Supertypes
-
class Objecttrait Matchableclass Any
- Self type
-
Tables.type
Types
An opaque type containing the parse table for the parser, and the factory of its initial context.
An opaque type containing the parse table for the parser, and the factory of its initial context.
The parse table is used to drive the LR parsing algorithm; its reductions carry the semantic actions of their productions. It is generated at compile time by analyzing the grammar rules. The initial context is built from the default values of the context's fields.
Type parameters
- Ctx
-
the parser context type
Attributes
- Source
- createTables.scala
