Recover %EDITC with a measured edit mask #611

Manually merged
binjovi-bot merged 2 commits from rpg-9-n-editc-20261022 into trunk 2026-10-22 23:04:11 +00:00
Owner

Recover %EDITC with a measured edit mask

  • New rpg_editc.zig: %EDITC(value: 'C') and %EDITC(value: 'C': '$' | *ASTFILL) are the store of the value in a packed temporary, the edit
    builtin call with the result temporary, the digits and an edit mask
    constant, then the typed store of the result. The mask is a function of
    the code, the digits and the decimal positions, and the compiler is
    deterministic, so a mask measured on a probe proves the code pair; the
    second code of a pair (2, 4, B, D, K, M, O, Q) blanks a zero value with a
    test before the edit (blanks, or asterisks and one blank with *ASTFILL).
    47 masks measured on h-editc and h-editc2 (batteries of 31 and 39
    forms, new probes), d4-editc-codes and d4-edit; h-editc2 emits
    without a failure line. A mask no probe
    measured keeps the statement unresolved; the dictionary batteries of the
    loop tooling add masks.
  • rpg_value_units.zig: the unit replaces the block with one operation
    that takes the value and gives the edited text. rpg_eval.zig: an edited
    text stored with the width of its mask fills the whole target, as a
    literal does, so the blank fill after the store folds into one
    assignment. rpg_source.zig: *ASTFILL is a word.
  • Not yet: %EDITC of an expression (i / 100) and under %TRIM (the
    exam's family); the unit and the masks are in place for them.

Gates

{"checks":{"net_statements":0},"census":{"statuses":{"recovered":645,"partial":0,"unresolved":0},"regressions":0,"newly_recovered":0},"emit":{"worse":[],"better":1,"newly_clean":1,"clean_delta":1,"base":202,"new":203},"twins":{"groups":405,"recovered":392,"regressions":[],"newly":2},"allgroups":{"regressions":[],"newly":[],"worse":[]},"full_check":{"exit":0,"seconds":768}}
# Recover %EDITC with a measured edit mask - New `rpg_editc.zig`: `%EDITC(value: 'C')` and `%EDITC(value: 'C': '$' | *ASTFILL)` are the store of the value in a packed temporary, the edit builtin call with the result temporary, the digits and an edit mask constant, then the typed store of the result. The mask is a function of the code, the digits and the decimal positions, and the compiler is deterministic, so a mask measured on a probe proves the code pair; the second code of a pair (2, 4, B, D, K, M, O, Q) blanks a zero value with a test before the edit (blanks, or asterisks and one blank with *ASTFILL). 47 masks measured on `h-editc` and `h-editc2` (batteries of 31 and 39 forms, new probes), `d4-editc-codes` and `d4-edit`; h-editc2 emits without a failure line. A mask no probe measured keeps the statement unresolved; the dictionary batteries of the loop tooling add masks. - `rpg_value_units.zig`: the unit replaces the block with one operation that takes the value and gives the edited text. `rpg_eval.zig`: an edited text stored with the width of its mask fills the whole target, as a literal does, so the blank fill after the store folds into one assignment. `rpg_source.zig`: `*ASTFILL` is a word. - Not yet: `%EDITC` of an expression (`i / 100`) and under `%TRIM` (the exam's family); the unit and the masks are in place for them. ## Gates ``` {"checks":{"net_statements":0},"census":{"statuses":{"recovered":645,"partial":0,"unresolved":0},"regressions":0,"newly_recovered":0},"emit":{"worse":[],"better":1,"newly_clean":1,"clean_delta":1,"base":202,"new":203},"twins":{"groups":405,"recovered":392,"regressions":[],"newly":2},"allgroups":{"regressions":[],"newly":[],"worse":[]},"full_check":{"exit":0,"seconds":768}} ```
binjovi-bot manually merged commit 1646158e1e into trunk 2026-10-22 23:04:11 +00:00
Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
sean/sourcerer!611
No description provided.