mirror of
https://github.com/storytold/gridcraft.git
synced 2026-10-30 05:37:00 -06:00
The review asked for the runner to be split. This pull request keeps the policy, the input checks, the step machine and `macro.run`; working out before a run where a macro writes (the footprint dry run, shifting data to make room, `macro.check`) moves to the pull request above it. - Unless the conflict rule is `overwrite`, every run now checks each step as it runs, which the run did before only after a partial footprint: a step that writes over cells outside the inputs that held data when the run started, or deletes sheets or objects that were there, stops the run, which asks (`ask`) or fails, and the run rolls back. - `shiftDown` and `shiftRight` need the footprint, so here they stop the run as `fail` does. - Moved: `Footprint`, `Saved`, `footprint`, `diff`, `make_room`, `macro.check`, the dry-run branches of the machine, `policy::previewable`, `DocState::touched` and the touch log, `Session::journal_dropped` and `truncate_journal`, and the tests of those. - Test: `each_step_is_checked_for_writes_over_data` (the review's counterexample: a permitted file step or Solver, then a write over B1, under `fail` and `ask`).