2.7 KiB
2.7 KiB
PBS AST Workshop 4
Status: Closed (2026-03-05)
Purpose
Close AST-facing diagnostics/recovery rules and Gate U evidence needed to finalize the AST contract.
Decisions To Produce
- Required diagnostics attribution behavior sourced from AST.
- Recovery invariants for parser output after syntax errors.
- Mandatory AST fixture corpus for Gate U evidence.
- Explicit deferred list for non-AST concerns.
Candidate Decisions
1. AST Must Sustain Diagnostics Fidelity
- Primary attribution for syntax diagnostics must remain stable and source-anchored.
- Cross-file related spans are attached when required by diagnostics rules.
2. Recovery Must Preserve Structural Integrity
- Recovered AST may be partial, but must remain structurally coherent.
- Recovery must not fabricate semantically valid shapes that hide syntax failure.
3. Gate U Evidence Baseline
- AST conformance evidence includes representative valid trees, invalid/recovery cases, and attribution assertions.
Questions To Resolve
- Which recovery behaviors are mandatory versus implementation-defined?
- What is the minimum fixture set to prevent AST regressions?
- Which AST-facing diagnostics codes must be frozen now?
Expected Outputs
- Decision note on AST diagnostics/recovery policy.
- Decision note on Gate U AST evidence baseline.
- Closure checklist for
11. AST Specification.md.
Decision Outcome (2026-03-05)
Decision record: docs/pbs/decisions/AST Diagnostics, Recovery, and Gate Evidence Decision.md.
- AST-facing syntax diagnostics must remain stable by identity (
code,severity,phase, primary attribution). - Human message text is locale-dependent and not the conformance identity key.
- Stable i18n identity is token/template-id based, aligned with diagnostics contract fields.
- Recovery is allowed for continued diagnostics, but recovered AST must stay structurally coherent with consistent attribution.
- Recovery must not mask real syntax failure by fabricating permissive valid AST shapes.
- Gate U AST evidence must include valid fixtures, malformed/recovery fixtures, diagnostics assertions, and attribution assertions.
- Mandatory negative fixture families include unexpected tokens, missing closers, forbidden non-associative chains, and unsupported forms with deterministic rejection.
Explicit Deferrals
- IRBackend lowering details (owned by
13), - backend/runtime/verifier concerns,
- compatibility/publication policy.
Inputs
docs/pbs/specs/11. AST Specification.mddocs/pbs/specs/12. Diagnostics Specification.mddocs/general/specs/13. Conformance Test Specification.mddocs/pbs/agendas/archive/11.3. AST Workshop 3 - Statements and Expressions.md