Skip to content

Commit beae18a

Browse files
Merge pull request #70 from mideind/grammar-hygiene
Grammar hygiene: variant diet and dead-rule fixes
2 parents bf285b8 + 0c9d910 commit beae18a

4 files changed

Lines changed: 96 additions & 114 deletions

File tree

CLAUDE.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -97,6 +97,11 @@ The public API is defined by the exports in `src/reynir/__init__.py`.
9797
- Grammar terminal and category names are Icelandic abbreviations (`no`=noun,
9898
`so`=verb, `nf`/`þf`/`þgf`/`ef`=cases, `et`/`ft`=number, `kk`/`kvk`/`hk`=gender);
9999
these appear throughout the code, tests and grammar files.
100+
- In the grammar, single-value variants ("eins gildis tilbrigði", e.g.
101+
`/p3 = p3`, `/et = et`) pin a nonterminal reference to one fixed variant
102+
value: `Tilvísunarsetning/tala/p3/kyn` unifies with the `p3` slice of a
103+
`/tala/pers/kyn` definition, since variant expansion is purely textual
104+
name generation. The value must be declared as a variant first.
100105
- Ruff line length is 88; `E731` (lambda assignment) is ignored.
101106
- CI (`.github/workflows/python-package.yml`) runs ruff + pytest via
102107
`uv sync --locked` on Python 3.10–3.14 and PyPy 3.11 on Linux, plus one

0 commit comments

Comments
 (0)