lean4-htt/src
Sebastian Graf a1240f7b80
fix: correct alternative-fold base in do match (#13491)
This PR fixes the `ControlInfo` inference for a do-block `match`: the
fold over the match arms started from `ControlInfo.pure` (defaults to
`numRegularExits := 1`, `noFallthrough := false`), but `alternative`
sums `numRegularExits` and ANDs `noFallthrough`, so the fold identity is
`{ numRegularExits := 0, noFallthrough := true }`. With the wrong base,
a `match` whose arms all `break`/`continue`/`return` reported
`numRegularExits = 1` and `noFallthrough = false`, suppressing the
dead-code warning on the continuation after the match. The fix corrects
both the inference handler in `InferControlInfo.lean` and the fold in
`elabDoMatchCore`.
2026-04-22 13:25:30 +00:00
..
bin perf: separate meta and non-meta initializers (#12016) 2026-02-26 08:05:19 +00:00
cmake fix: use commondir to resolve git directory in worktrees (#13045) 2026-04-11 06:45:02 +00:00
include/lean fix: file read buffer overflow (#13392) 2026-04-13 17:56:27 +00:00
Init chore: remove repeat/while macro_rules bootstrap from Init.While (#13479) 2026-04-19 21:01:14 +00:00
initialize
kernel chore: fix spelling errors (#13274) 2026-04-04 07:34:34 +00:00
lake chore: lake: rm autoParam in Lake.Load.Resolve (#13495) 2026-04-21 21:43:40 +00:00
Lean fix: correct alternative-fold base in do match (#13491) 2026-04-22 13:25:30 +00:00
library fix: potential Array.get!Internal leaks part 2 (#13148) 2026-03-27 02:51:39 +00:00
runtime fix: two bugs in io.cpp (#13427) 2026-04-16 12:38:17 +00:00
shell chore: move test suite setup to tests/CMakeLists.txt (#12278) 2026-02-03 13:22:20 +00:00
Std feat: introduce HTTP/1.1 server (#12151) 2026-04-20 16:25:45 +00:00
util feat: allow deprecating options (#13195) 2026-04-02 14:44:11 +00:00
cadical.mk
CMakeLists.txt fix: pass CMake Lake args to the Lake make build (#13410) 2026-04-14 22:07:29 +00:00
config.h.in
githash.h.in
Init.lean chore: revert "feat: add lake builtin-lint (#13422) 2026-04-15 19:28:59 +00:00
lakefile.toml.in chore: use weakLeanArgs for Lake plugin (#13335) 2026-04-09 00:02:39 +00:00
lean-toolchain chore: relative lean-toolchains (#12652) 2026-02-25 10:23:35 +00:00
Lean.lean refactor: move getOriginalConstKind? into its own module to avoid future import cycle (#12265) 2026-02-01 16:18:51 +00:00
lean.mk.in
Leanc.lean
LeanChecker.lean refactor: remove Lean.Environment.replay from core (#12972) 2026-03-18 22:11:42 +00:00
LeanIR.lean chore: fixes from #13103 "enable separate codegen" (#13241) 2026-04-02 11:13:22 +00:00
out
Std.lean
stdlib.make.in fix: pass CMake Lake args to the Lake make build (#13410) 2026-04-14 22:07:29 +00:00
stdlib_flags.h chore: consistent build flags between USE_LAKE ON and OFF (#12941) 2026-03-17 11:02:55 +00:00
version.h.in