QA round 1: adversarial review logs and a with-block attack test

No blocking findings over the 8 round-1 clusters: whole-corpus idempotency
and comment-preservation sweep clean (796/820), 476-run mutation fuzz clean,
no swallowed errors in the diff. Adds
reindented_string_inside_a_with_block_is_rejected. Findings (non-blocking)
are in each feature README's QA log; the printer fits() / Doc::Inline gap
is fixed separately.

Co-Authored-By: Claude Fable 5 <[email protected]>
This commit is contained in:
lucioandClaude Fable 5 committed 2026-08-21 01:37:33 -07:00
1 parent f1db1e5746
commit 0557933994
9 files changed
+400 -8

No files matched your search

+38 -1
View File
@@ -198,4 +198,41 @@ instantiation too (`bind.cases`, "implicit named *parameter* overrides").
## QA log
## Review
### 2026-08-21 — round-1 adversarial QA
Verified: `cargo test --workspace`/clippy/fmt clean; corpus score 796/820;
whole-corpus idempotency + comment-preservation sweep clean; 476-case mutation
fuzz clean.
Targeted attacks:
- **`bind` recognized by shape, not keyword — `obj.bind()` must still
parse.** Confirmed: `obj.bind(); obj.bind(1, 2);` (method calls named
`bind`) format unchanged, not confused with the directive.
- **Indexed hierarchical bind targets are a clean parse error.** Confirmed:
`bind dut[3] checker_mod c_inst(.clk(clk));` → `parse error: 2:15: expected
';' (found "checker_mod")`, exit 2, zero bytes on stdout. Clean rejection,
not corruption, matches the dev's own note.
- **Comment placement inside a `bind` directive.** Found a real (but
non-corrupting) gap: a comment sitting between `bind` and the target name —
`bind /*c1*/ dut checker_mod c_inst(.clk(clk));` — is **not** currently
reproduced by the formatter's internal `Doc` construction; the safety net
catches it (`verify_equivalence`: "token stream diverges ... input has
comment `/*c1*/` at 2:8, output has identifier `dut` at 2:8") and the CLI
exits 2 with zero bytes written to stdout. Root cause: `parse_bind`
(parser.rs, `fn parse_bind` — target-name parsing via `expect_ident()`
around parser.rs:2627) never routes through `take_meta()`/the comment
bucket the way ordinary item/list elements do, so a comment landing exactly
there has nowhere to attach and gets dropped internally — but the net
refuses to let that reach the file. **NON-BLOCKING** per the hard
invariants (no corruption occurred; input is left untouched on disk), but
worth a follow-up: comments in that position currently make the file
unformattable via vfmt rather than being preserved and formatted. Same
class of gap reproduces for a comment right after the module name / before
the instance name of the `bind`'s instantiation tail — not otherwise
explored in depth.
No BLOCKING findings for this cluster.