Procházet zdrojové kódy

docs: note the forward-resolution relocation in the plan

Eric Streit před 2 dny
rodič
revize
1e644379d6
1 změnil soubory, kde provedl 18 přidání a 0 odebrání
  1. 18 0
      docs/plan-resolve-check.md

+ 18 - 0
docs/plan-resolve-check.md

@@ -189,3 +189,21 @@ Measured while scaffolding (branch `resolve-check`):
   base, its resolved symbol (needs a new field, or reuse the existing
   node-id slot) so `Lower` can stop re-deriving.
 
+### Progress
+
+- **2026-10-15 (`f34ca98`)** — the forward-reference *resolution* half
+  moved out of the grammar into `Check` (`NoteForward`/`FlushForward`,
+  driven from `Resolve`, which the driver calls for every unit).  To run
+  it post-parse, resolution is now scope-independent: `SymTab` records
+  the scope at `FwdVarRef` time (`fwdVarScope`) and `FwdVarResolve`
+  walks up from it via a new `FindScope` (`Find` is a thin wrapper).
+  The grammar's `FwdVarNote`/`FwdVarFlush`, `nFvarRefs`/`fvarId`/
+  `fvarSlot` and its four flush call sites are gone; `SymTab.FwdVarType`
+  was dead and is removed.
+- **Consequences for §9**: step 4 must also delete `Check.NoteForward`/
+  `FlushForward` (replaced by real binding in the walk).
+- **Note**: `-noresolve` now disables the forward fix-up too (it turns
+  off the whole `Check` pass); on forward-free code it stays
+  byte-identical, so the suite gate is unaffected.
+
+