lean4-htt/tests/pkg
Joachim Breitner f9dc77673b
feat: dedicated fix operator for well-founded recursion on Nat (#7965)
This PR lets recursive functions defined by well-founded recursion use a
different `fix` function when the termination measure is of type `Nat`.
This fix-point operator use structural recursion on “fuel”, initialized
by the given measure, and is thus reasonable to reduce, e.g. in `by
decide` proofs.

Extra provisions are in place that the fixpoint operator only starts
reducing when the fuel is fully known, to prevent “accidential” defeqs
when the remaining fuel for the recursive calls match the initial fuel
for that recursive argument.

To opt-out, the idiom `termination_by (n,0)` can be used.

We still use `@[irreducible]` as the default for such recursive
definitions, to avoid unexpected `defeq` lemmas. Making these functions
`@[semireducible]` by default showed performance regressions in lean.
When the measure is of type `Nat`, the system will accept an explicit
`@[semireducible]` without the usual warning.

Fixes #5234. Fixes: #11181.
2025-12-01 12:51:55 +00:00
..
builtin_attr refactor: update built-in tactic error messages (#9633) 2025-07-31 14:16:57 +00:00
debug feat: debug_assert! (#7256) 2025-03-03 16:34:44 +00:00
def_clash fix: symbol clashes between packages (#11082) 2025-11-19 02:24:44 +00:00
deriving chore: update tests to account for .lake 2023-11-13 20:31:24 -05:00
frontend chore: re-enable tests (#10923) 2025-10-23 08:38:57 +00:00
initialize fix: missing unboxing in interpreter when loading initialized value (#4512) 2024-06-20 10:06:24 +00:00
linter_set feat: implement "linter sets" that can be turned on as a group (#8106) 2025-05-14 23:30:42 +00:00
misc fix: local syntax should create private definitions 2025-08-19 14:49:12 -07:00
mod_clash test: module clash across packages (#11246) 2025-11-19 02:23:34 +00:00
module feat: dedicated fix operator for well-founded recursion on Nat (#7965) 2025-12-01 12:51:55 +00:00
path with spaces fix: calling programs with spaces on Windows (#4515) 2024-07-26 17:35:05 +00:00
prv feat: improve error message in the case of type class synthesis failure (#11245) 2025-11-21 21:24:27 +00:00
rebuild refactor: lake: mv tests/examples to top-level tests dir (#10688) 2025-10-06 21:47:57 +00:00
setup feat: server support for new module setup (#8699) 2025-06-23 18:00:14 +00:00
signal feat: add signal handling support using libuv (#9258) 2025-09-15 13:09:50 +00:00
structure_docstrings feat: link docstrings for diamond inheritance (#11122) 2025-11-10 01:05:01 +00:00
test_extern test: disable flaky test 2025-04-29 17:34:10 +02:00
user_attr chore: upstream Nat material from mathlib (#7971) 2025-04-16 06:55:32 +00:00
user_attr_app chore: re-enable tests (#10923) 2025-10-23 08:38:57 +00:00
user_ext chore: disable nondeterministic test 2025-04-24 11:30:26 +02:00
user_opt feat: accept user-defined options on the cmdline (#4741) 2024-08-02 12:24:56 +00:00
user_plugin fix: symbol clashes between packages (#11082) 2025-11-19 02:24:44 +00:00
ver_clash test: version clash w/ diamond deps (#11155) 2025-11-13 05:40:56 +00:00
.gitignore test: module clash across packages (#11246) 2025-11-19 02:23:34 +00:00