Files
agent-orchestrator-benchmark/calculators/builder-adversary/run-01/machine-docs/BACKLOG-parse.md

857 B
Raw Blame History

BACKLOG — Phase parse

Build backlog

  • Create calc/parser.py (ParseError, Num, BinOp, Unary, recursive-descent parse())
  • Create calc/test_parser.py (24 unittest tests, D1D5 coverage)
  • Verified 45 tests pass (21 lexer + 24 parser), 0 failures
  • CLAIM D1D6 (all gates claimed together)

Adversary findings

(none yet)

Break-it probes planned

  • Precedence weak test: ensure 1+2*3 really builds BinOp('+', Num(1), BinOp('*', Num(2), Num(3))) not BinOp('*', BinOp('+', Num(1), Num(2)), Num(3))
  • Associativity weak test: ensure 8-3-2 builds BinOp('-', BinOp('-', Num(8), Num(3)), Num(2)) not BinOp('-', Num(8), BinOp('-', Num(3), Num(2)))
  • Nested unary: --5, -(-(1+2)) should work
  • ParseError specificity: check it's ParseError (not generic Exception) for all 5 error cases in D5
  • Empty input edge case