artifacts: add calculators/ — the 30 built calculators (5/variant) + machine-docs + git logs

This commit is contained in:
2026-06-16 15:39:42 +00:00
parent 64bc360fc0
commit bb85aa9f11
728 changed files with 34148 additions and 0 deletions
@@ -0,0 +1,13 @@
# Journal — phase `lex`
## 2026-06-15
Built `calc/lexer.py` with `Token` dataclass, `LexError`, and `tokenize()`.
Design notes:
- `Token` is a dataclass with `kind: str` and `value: Union[int, float, str, None]`; EOF has `value=None`, operators carry their char as value, numbers carry the parsed numeric value.
- Number parsing: scans while digit or `.`; uses `int()` if no dot else `float()`.
- LexError message includes the offending character (quoted) and its 0-based position.
- 18 tests cover all D1D3 requirements including the plan's required expressions.
Committed ba1f056, then c465844 (STATUS sha update). Waiting for Adversary review.