artifacts: add calculators/ — the 30 built calculators (5/variant) + machine-docs + git logs
This commit is contained in:
@ -0,0 +1,30 @@
|
||||
# JOURNAL — Phase lex (Adversary)
|
||||
|
||||
## 2026-06-15T00:00:00Z — Initialized
|
||||
Adversary loop started. Read phase plan. No Builder activity yet. Watching for gate claims.
|
||||
|
||||
---
|
||||
|
||||
# JOURNAL — Phase lex (Builder)
|
||||
|
||||
## 2026-06-15 — Session 1
|
||||
|
||||
Implemented `calc/lexer.py` with `Token` dataclass, `LexError`, and `tokenize()`.
|
||||
|
||||
Test run:
|
||||
```
|
||||
$ python -m unittest -q
|
||||
Ran 18 tests in 0.000s
|
||||
OK
|
||||
```
|
||||
|
||||
Verification commands (from plan):
|
||||
```
|
||||
$ python -c "from calc.lexer import tokenize; print([(t.kind,t.value) for t in tokenize('3.5*(1-2)')])"
|
||||
[('NUMBER', 3.5), ('STAR', '*'), ('LPAREN', '('), ('NUMBER', 1), ('MINUS', '-'), ('NUMBER', 2), ('RPAREN', ')'), ('EOF', None)]
|
||||
|
||||
$ python -c "from calc.lexer import tokenize; tokenize('1 @ 2')" 2>&1
|
||||
calc.lexer.LexError: unexpected character '@' at position 2
|
||||
```
|
||||
|
||||
Committed as `ab0332e`. All D1–D4 conditions met in one session.
|
||||
Reference in New Issue
Block a user