Sebastian Ullrich
c5114c971a
fix: Windows needs more LEAN_EXPORTs
2024-08-12 14:14:42 +02:00
Joachim Breitner
c4718a87ab
refactor: constructions: modify environment in lean world ( #4474 )
...
this is a first step towards porting the code `constructions.cpp` to
Lean: It leaves the construction of the `Declaration` untouched, but
moves adding the declarations to the environment, and setting various
attributes, to the Lean world.
This allows the remaining logic (the construction of the `Declaration`)
to be implemented in Lean separately and easily compared to the C++
implementation, before we replace that too.
To that end, `Declaraion` gains an `BEq` instance.
---------
Co-authored-by: Leonardo de Moura <leomoura@amazon.com>
Co-authored-by: Arthur Adjedj <arthur.adjedj@ens-paris-saclay.fr>
2024-06-19 08:58:53 +00:00
Leonardo de Moura
50ac21d0a6
refactor: move is_constructor_app to inductive.cpp
2021-11-25 11:31:00 -08:00
Leonardo de Moura
80a73dd903
feat: basic support for definitions at inductive declarations
2021-10-25 12:44:35 -07:00
Sebastian Ullrich
74c2d1dca9
chore: remove io_state & abstract_type_context
2021-01-12 09:51:14 -08:00
Leonardo de Moura
01f8bcfc87
chore: remove dead code
2020-10-27 19:23:14 -07:00
Leonardo de Moura
7a24fe73ca
chore: remove dead code
2020-10-25 20:49:30 -07:00
Leonardo de Moura
ea5eed7964
fix: do not assume the constructor name prefix is the inductive type name
2020-07-23 14:36:54 -07:00
Leonardo de Moura
e596820f2e
chore: remove () modifier
...
cc @Kha
2020-05-12 15:02:02 -07:00
Leonardo de Moura
50207e2c5a
chore(library/constants.txt): remove dead variables
2019-03-22 13:26:48 -07:00
Leonardo de Moura
2be87ecd92
chore(library/init): Bool.tt => Bool.true and Bool.ff => Bool.false
2019-03-21 15:06:44 -07:00
Leonardo de Moura
0888dee25e
chore(*): meta ==> unsafe
2019-03-15 15:04:40 -07:00
Leonardo de Moura
0cb3ac683d
feat(library/compiler): connect new const_folding module implemented in Lean with csimp
2019-02-15 14:37:48 -08:00
Leonardo de Moura
9675b7c952
fix(frontends/lean/elaborator): ignore mdata when processing field notation
2019-02-11 17:29:38 -08:00
Leonardo de Moura
097aa7ef14
chore(library/compiler): cleanup cce
2018-09-21 10:25:35 -07:00
Leonardo de Moura
2abe11ce63
chore(library): _meta_aux ==> _meta_rec
2018-09-17 09:08:12 -07:00
Leonardo de Moura
58e91559d0
feat(*): use new inductive datatype module
2018-09-06 18:09:22 -07:00
Leonardo de Moura
f335623530
feat(library/constructions/brec_on): add below and ibelow for new inductive datatype module
2018-09-05 14:46:03 -07:00
Leonardo de Moura
92c4b2ee0d
chore(library/util): minor
2018-09-05 14:46:03 -07:00
Leonardo de Moura
4964ad660f
feat(library/constructions/no_confusion): add no_confusion for new inductive datatype module
2018-09-05 10:27:49 -07:00
Leonardo de Moura
4773a3be5f
feat(library/constructions/no_confusion): add no_confusion_type for new inductive datatype module
2018-09-05 09:55:13 -07:00
Leonardo de Moura
dd03747d22
chore(kernel): univ_param vs lparam, level_param_names ==> names, and other inconsistencies
2018-09-03 13:05:42 -07:00
Sebastian Ullrich
8033649335
chore(library/util): fix doc
2018-08-01 18:44:23 -07:00
Leonardo de Moura
c0e1d05199
chore(kernel): type_checker ==> old_type_checker
2018-06-06 16:10:40 -07:00
Sebastian Ullrich
f3ca420b64
feat(frontends/lean/elaborator): hide opt/auto param types when elaborating structure field values
2018-02-28 12:49:22 +01:00
Leonardo de Moura
f8e0916c64
feat(library/tactic, frontends/lean): replace a few mk_tagged_fresh_name with mk_unused_name
2018-02-21 15:04:19 -08:00
Leonardo de Moura
cc8eb83507
refactor(library/util,util): move is_internal_name to util/
2018-02-21 15:04:19 -08:00
Sebastian Ullrich
1ee945a31f
fix(library): store and validate Lean version of .olean files
...
Fixes #1770
2018-01-23 11:14:18 -08:00
Leonardo de Moura
c5df94ed17
feat(library/tactic): add support for auto params at simp tactic
2018-01-11 16:47:22 -08:00
Leonardo de Moura
ef784ce7b8
fix(library/tactic/simp_lemmas): auto_params when adding simp lemmas
2017-12-09 09:47:39 -08:00
Leonardo de Moura
14301a7f9f
feat(library/equations_compiler/compiler): generate meta auxiliary definitions for regular (recursive) definitions
...
Motivations:
- Clear execution cost semantics for recursive functions.
- Auxiliary meta definition may assist recursive definition unfolding in the type_context object.
Next step: use meta auxiliary definition at code generation.
2017-11-01 11:58:45 -07:00
Sebastian Ullrich
46c1a1a844
refactor(frontends/lean/elaborator,kernel/error_msgs): remove duplicate code
2017-07-21 01:46:31 -07:00
Daniel Selsam
538ac8d187
feat(inductive_compiler): generate injectivity lemmas
2017-03-10 22:27:18 -08:00
Leonardo de Moura
6b3e651de7
fix(library/util): get_datatype_level should not assume inductive datatype result type is a sort
...
It may be something that is reducible to a sort.
2017-03-02 11:42:16 -08:00
Leonardo de Moura
1542cd750f
feat(library/tactic/induction_tactic): use drec in the induction tactic
...
The new test failed before this change.
2017-03-01 18:34:24 -08:00
Leonardo de Moura
d1d5428808
feat(library): add check_constants.lean validation, cleanup unused names, minor stdlib fixes
2017-02-21 10:45:31 -08:00
Leonardo de Moura
797b26f402
fix(frontends/lean/tactic_notation): trace messages in nested blocks were not being displayed in the correct place
2017-02-05 18:20:10 -08:00
Leonardo de Moura
d315e424ff
feat(library/congr_lemma, library/fun_info): make sure opt_param gadget do not confuse the simplifier, fun_info, congr_lemma, etc
...
A definition such as
def f (a : nat) (b : nat := a) (c : nat := a) :=
a + b + c
should *not* be treated as a dependent function.
2017-01-30 20:23:45 -08:00
Leonardo de Moura
a6f26f0b74
chore(library): poly_unit ==> punit
...
psum, pprod and punit are used internally.
see #1341
2017-01-30 11:54:00 -08:00
Leonardo de Moura
bf9f7560f7
feat(frontends/lean): (Type u) can't be a proposition
...
(Type u) is the old (Type (u+1))
(PType u) is the old (Type u)
Type* is the old (Type (_+1))
PType* is the old Type*
The stdlib can be compiled, but we still have > 70 broken tests
See discussion at #1341
2017-01-30 11:54:00 -08:00
Leonardo de Moura
fc00275636
fix(library/compiler/elim_recursors): it was assuming that recursive arguments occur after non recursive ones
2017-01-16 22:59:17 -08:00
Leonardo de Moura
acef1efb86
fix(frontends/lean/pp,library/equations_compiler,library/tactic/smt/congruence_closure): bug at to_char function
2017-01-11 23:44:25 -08:00
Leonardo de Moura
8a12c834ca
fix(library/tactic/smt/ematch): ematch should not use app_builder since its type_context is already in tmp_mode
2017-01-07 17:06:12 -08:00
Leonardo de Moura
5e3f26ec95
feat(library/tactic/smt/congruence_closure): propagate not_exists
2017-01-06 14:00:36 -08:00
Leonardo de Moura
316507081c
feat(library/tactic/smt): unit propagation interface
2017-01-02 10:28:26 -08:00
Leonardo de Moura
b313328cb9
feat(library/equations_compiler): int constants
2016-12-25 10:00:18 -08:00
Leonardo de Moura
3061d8b9a3
feat(library): add mk_int_val_ne_proof
2016-12-24 15:22:31 -08:00
Leonardo de Moura
d431d7274a
feat(library/tactic/congruence/congruence_closure): hard code support for ne
2016-12-23 15:37:05 -08:00
Leonardo de Moura
48cd421852
feat(library/tactic/congruence): add congruence closure basics
2016-12-21 20:46:25 -08:00
Leonardo de Moura
9aa77bfdb0
feat(library/util): add mk_nat
2016-12-06 00:16:31 -08:00