Commit 570ee45
syntax(L2 Phase 2 / Phase D slice 1): add TFunEff effect-typed function constructor (#200)
## Summary
- Adds `TFunEff T1 T2 R_in R_out` to `ty` in `Syntax.v`, paralleling the
existing `TFun T1 T2` (which is preserved per CLAUDE.md owner directive
— the legacy `TFun` + `preservation`'s falsity is load-bearing for
`Counterexample.v`).
- `TFunEff` exposes a lambda body's R-flow at the type level: required
for closing the lambda-rigidity admit at `Semantics_L1.v:1694` and
naturally unblocking the deferred Phase B Slice 1 + Phase C work.
- Slice 1 of 4 — syntax-only landable shape, mirrors L3 wiring slice 1 +
Phase A's docs-only PR #197.
## What changed
- `Syntax.v` — `TFunEff : ty -> ty -> list region_name -> list
region_name -> ty` constructor.
- `Typing.v` `free_regions` — extends fixpoint with TFunEff case (union
of argument/return free regions + R_in + R_out).
- `is_linear_ty` (catch-all `_ => false`) — automatically false for
TFunEff. No change needed.
## What's NOT in this PR
- Typing rules `T_Lam_L1_*_Eff` / `T_App_L1_Eff` → slice 2
- Preservation closure for lambda-rigidity → slice 3
- Phase B + Phase C re-attempt → slice 4
## Test plan
- [x] `coqc 8.18.0` clean rebuild — 10/10 .v files Qed (no proof
regressions)
- [x] Zero new Admitted / Axiom (per CLAUDE.md directive)
- [x] No legacy Semantics.v / Typing.v judgment patching (only fixpoint
extended for new case)
- [ ] Slice 2 to follow once this lands
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>1 parent 7a64296 commit 570ee45
2 files changed
Lines changed: 36 additions & 10 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
60 | 60 | | |
61 | 61 | | |
62 | 62 | | |
63 | | - | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
64 | 85 | | |
65 | 86 | | |
66 | 87 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
54 | 54 | | |
55 | 55 | | |
56 | 56 | | |
57 | | - | |
58 | | - | |
59 | | - | |
60 | | - | |
61 | | - | |
62 | | - | |
63 | | - | |
64 | | - | |
65 | | - | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
66 | 71 | | |
67 | 72 | | |
68 | 73 | | |
| |||
0 commit comments