Commit graph

29801 commits

Author SHA1 Message Date
Leonardo de Moura
dbe9bf61c5 fix: unfold auxiliary theorems created by decreasing_tactic 2022-02-23 09:02:23 -08:00
Leonardo de Moura
4794b9709f feat: improve equation theorem and match-splitter generation at MatchEqns.lean 2022-02-22 17:43:42 -08:00
Leonardo de Moura
52ff840321 feat: support for HEq at injection 2022-02-22 17:24:11 -08:00
Leonardo de Moura
c9f8ec71df fix: invalid rewrite when proving equation theorems for declaration using well-founded recursion 2022-02-22 16:38:51 -08:00
Leonardo de Moura
d36027d2fa test: add Certificate.of_combine_isUnsat 2022-02-22 16:04:23 -08:00
Leonardo de Moura
24249fecd3 feat: helper simp theorems 2022-02-22 16:03:36 -08:00
Leonardo de Moura
8d6750469e chore: helper Nat theorems 2022-02-22 14:26:50 -08:00
Leonardo de Moura
77fc0d3223 test: cleanup 2022-02-22 07:23:07 -08:00
Leonardo de Moura
c932d9d33c test: combine two inequalities 2022-02-21 15:13:37 -08:00
Leonardo de Moura
c73d177c94 perf: simpH? at MatchEqns.lean 2022-02-21 12:04:03 -08:00
Leonardo de Moura
0e40c63292 chore: fix typo 2022-02-21 10:55:38 -08:00
Leonardo de Moura
e9ee8ee86f test: add cancelation theorems for <= and < 2022-02-21 08:49:50 -08:00
Leonardo de Moura
7f3a3138d0 feat: helper Nat theorems 2022-02-21 08:49:50 -08:00
Sebastian Ullrich
d39c23f061 feat: quot precheck for 2022-02-21 10:14:39 +01:00
Leonardo de Moura
0986696758 test: add cancelation example 2022-02-20 17:35:33 -08:00
Leonardo de Moura
a8427702e8 test: reverse direction for cancelation procedure 2022-02-20 17:03:11 -08:00
Leonardo de Moura
33b1d2fd98 fix: preserve arrow binder names and info at simp
We use the idiom `revert; simp; ...; intro` in a few places. Some of
the reverted hypotheses manifest themselves as arrows in the target.
Before this commit, `simp` would lose the binder names and info when
simplifying an arrow, and we would get inaccessible names when
reintroducing them.
2022-02-20 16:27:40 -08:00
Leonardo de Moura
4ccab41819 test: proof by reflection example 2022-02-20 10:11:40 -08:00
Leonardo de Moura
cf0f7a30c4 test: add Monomials.cancel 2022-02-19 21:29:33 -08:00
Leonardo de Moura
ba16903205 feat: add helper theorems 2022-02-19 21:25:44 -08:00
Leonardo de Moura
855b71299f test: arith by reflection 2022-02-19 17:54:32 -08:00
Leonardo de Moura
193859c72c feat: add helper theorems 2022-02-19 17:53:54 -08:00
Leonardo de Moura
7a13eaea8d chore: update stage0 2022-02-19 08:11:17 -08:00
Leonardo de Moura
7a81589c49 feat: improve "constant approximation" heuristic used at isDefEq 2022-02-19 08:09:31 -08:00
Leonardo de Moura
19bcb5fb31 feat: add Array.popWhile and Array.takeWhile 2022-02-19 07:04:52 -08:00
Leonardo de Moura
a4d6cbfedd feat: improve match elaborator 2022-02-19 06:12:21 -08:00
Leonardo de Moura
f64f563936 chore: fix comment 2022-02-19 06:11:53 -08:00
Leonardo de Moura
e61d0be561 feat: isolate fixed prefix at well-founded recursion
closes #1017
2022-02-18 10:40:32 -08:00
Leonardo de Moura
75e771b6e8 feat: add support for fixed argument prefix at mkFix and elabWFRel
This is needed for #1017

TODO: `addNonRecPreDefs` and equation theorems
2022-02-18 07:59:32 -08:00
Leonardo de Moura
70312191f7 feat: make sure packDomain and packMutual ignore the fixed arguments
TODO: adapt `elabWFRel`, `mkFix`, and etc.

This is needed for #1017
2022-02-17 17:43:06 -08:00
Leonardo de Moura
9ee529e5ce fix: use PSum instead of Sum when using well-founded recursion
See new test for example that did not work with `Sum` because type
alpha was `Sort u`.
2022-02-17 16:14:34 -08:00
Leonardo de Moura
4a0ae8326c feat: compute the fixed prefix size for mutually recursive definitions 2022-02-17 14:12:05 -08:00
Leonardo de Moura
3f0be7901e chore: update stage0 2022-02-17 10:52:34 -08:00
Leonardo de Moura
dedb6ee01b fix: skip value if type is computationally irrelevant 2022-02-17 10:41:16 -08:00
Leonardo de Moura
ba0904060b chore: missing trace_pp_expr 2022-02-17 10:40:21 -08:00
Leonardo de Moura
4ed5c8405b feat: improve IR checker error messages 2022-02-17 09:51:05 -08:00
Leonardo de Moura
6b1297fe85 chore: update stage0 2022-02-16 13:52:28 -08:00
Xubai Wang
ca521e1188 feat: add position to mod doc 2022-02-16 13:50:19 -08:00
Leonardo de Moura
373a64ee09 test: for isNoncomputable 2022-02-16 13:37:49 -08:00
Leonardo de Moura
9d6c26a4a6 chore: update stage0 2022-02-16 13:33:33 -08:00
Leonardo de Moura
e1d9dc4b38 feat: store noncomputable declarations 2022-02-16 13:33:02 -08:00
Leonardo de Moura
31e90c8f65 chore: update stage0 2022-02-16 13:22:44 -08:00
Leonardo de Moura
4ba1e0ad4b feat: add isNoncomputable function for querying whether a given declaration has been marked as "noncomputable" by users 2022-02-16 13:20:31 -08:00
Leonardo de Moura
ad5099ec3c fix: mkLetRecClosureFor for nested let-recs
closes #1020
2022-02-16 12:44:02 -08:00
Leonardo de Moura
86328bcb9f feat: tail recursive List.iota and [csimp] theorem 2022-02-16 11:25:46 -08:00
Leonardo de Moura
d46d246cd9 fix: documentation 2022-02-15 16:19:35 -08:00
Leonardo de Moura
80bb1454c5 doc: add example to RELEASES.md 2022-02-15 16:09:36 -08:00
Leonardo de Moura
3f4d8f370a fix: backtrack InfoTree when backtracking at the discriminant refinement method
This commit addresses issue described at https://github.com/leanprover/lean4/issues/1018#issuecomment-1040597212

closes #1018
2022-02-15 16:01:09 -08:00
Leonardo de Moura
fd9165415e feat: try to preserve variable names during discriminant refinement
This fixes second issue at #1018
2022-02-15 15:54:03 -08:00
Leonardo de Moura
56cdacfc28 feat: allow synthetic holes to be used as patterns
They are useful for getting meaningful pattern variable names when the hole
is not an inaccessible pattern. See new test.

We are going to use this feature to address issue 2 at #1018.
2022-02-15 15:34:14 -08:00