Repository navigation
Commit 29217e5
committed
fix(stack-encrypt): address the review of the planned lowering
The review of #1597 found five in-diff mutants surviving. Three were
equivalent: the "keys nothing" distinction in `compose` under a label
context, where a passthrough ignores its context either way, and the
context-field disjunct of the predicate, dead because a context field
is always a passthrough. The distinction is removed rather than
excluded. Two were checks nothing reached: `check_stored` and
`check_names` are now reached by unit tests in `planned.rs`.
`validate` is deleted. Its duplicate-field and label rules were refused
by the parser first; the one live rule, shared identity between keyed
fields, is in `Plan::build`'s loop beside the target rule. The
builder's `join`, `field_label`, `FROM_PLAN` and `FROM_CALL` are shared
with the lowering rather than copied. A target field is skipped by
`operation_of` returning `None`, so no `unreachable!` sits in library
code. Docs that still described lowering through the builder, or that
said the checks run the lowering, are reworded: the checks share
`check_names`, `check_stored` and `opening_base` with it.
Tests added: a context field declared last, a batch with absent fields
under a context field opened with an expected context, the stored and
value checks refusing each kind of misfit, and the shared-identity
table with exact reasons.
Refs #1488.1 parent 94c89c2 commit 29217e5
8 files changed
Lines changed: 524 additions & 196 deletions
File tree
- docs/plans
- packages/stack-encrypt
- docs/adr
- src
- dynamic
- plan
- target
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1998 | 1998 | | |
1999 | 1999 | | |
2000 | 2000 | | |
2001 | | - | |
2002 | | - | |
| 2001 | + | |
| 2002 | + | |
| 2003 | + | |
2003 | 2004 | | |
2004 | 2005 | | |
2005 | 2006 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
57 | 57 | | |
58 | 58 | | |
59 | 59 | | |
60 | | - | |
61 | | - | |
62 | | - | |
63 | | - | |
64 | | - | |
65 | | - | |
66 | | - | |
67 | | - | |
68 | | - | |
69 | | - | |
70 | 60 | | |
71 | 61 | | |
72 | 62 | | |
| |||
500 | 490 | | |
501 | 491 | | |
502 | 492 | | |
| 493 | + | |
| 494 | + | |
| 495 | + | |
| 496 | + | |
| 497 | + | |
| 498 | + | |
| 499 | + | |
| 500 | + | |
| 501 | + | |
503 | 502 | | |
504 | 503 | | |
505 | 504 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
382 | 382 | | |
383 | 383 | | |
384 | 384 | | |
| 385 | + | |
| 386 | + | |
| 387 | + | |
385 | 388 | | |
386 | 389 | | |
387 | 390 | | |
| |||
0 commit comments