Expand description
Parsing helpers for compact dice roll expressions. Parsers for compact dice roll expressions.
Expressions are provided as already-tokenized command-line style strings,
such as ["3d6", "d20", "5"]. Dice counts are expanded into repeated die
names and integer tokens are treated as modifiers where allowed.
Structs§
- Parsed
Roll - Parsed roll input.
Functions§
- parse_
dice_ only_ exprs - Parses dice expressions and rejects integer modifiers.
- parse_
roll_ exprs - Parses dice expressions and integer modifiers.