Leonardo de Moura
d34386fef7
perf(frontends/lean/tactic_notation): closes #1345
...
We can now elaborate
https://gist.github.com/gebner/439273deee592603190d4f8b4447295b
in 1.6 secs and using less than 500Kb of stack space.
It was takins 44 secs and 5Mb before this commit.
Two modifications:
1) Use pre_monad.seq instead of pre_monad.and_then.
They have the same implementation, but seq is not marked as [inline].
2) Modify how we concatenate the tactics in a begin...end block.
Before: (((a_1 ++ a_2) ++ a_3) ++ a_4)
After: ((a_1 ++ a_2) ++ (a_3 ++ a_4))
2017-01-30 14:13:53 -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
9107439bce
feat(frontends/lean/elaborator): default parameter prototype
...
See #1340
2017-01-27 16:32:22 -08:00
Leonardo de Moura
cce88c6190
refactor(frontends/lean): interactive tactic support
...
After this commit, new interactice tactic classes can be added without
writing C++ code (see example: tests/lean/run/my_tac_class.lean).
The tactic_evaluator was simplified, and all the complexity has been
moved to tactic_notation, and lean code.
We can now inspect the intermediate states produced by the rewrite
tactic.
The function (@scope_trace _ line col thunk) can be used to position trace
messages produced by thunk. If line/col are not provided (i.e., we
just write (scope_trace thunk)), then line/col are filled with the
position of this term by the elaborator.
We can visualize the intermediate tactic states inside nested blocks
such as (try { ... })
The new infrastructure can be used to implement custom tactic_state
pretty printers.
2017-01-21 22:38:47 -08:00
Leonardo de Moura
e8839cbcdc
feat(library/app_builder): add mk_eq_mpr that removes unnecessary propext
2017-01-20 20:27:41 -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
7ba889b5cf
feat(frontends/lean/tactic_notation): try/repeat for smt_tactic in interactive mode
2017-01-05 18:31:57 -08:00
Leonardo de Moura
5f2b247af9
feat(frontends/lean/tactic_evaluator): step-by-step evaluation for 'begin [smt] ... end' blocks
2017-01-04 14:06:44 -08:00
Leonardo de Moura
ca6d3743c7
feat(library/tactic/smt): add mk_eq_true_intro mk_of_eq_true mk_eq_false_intro mk_not_of_eq_false
2017-01-02 13:39:16 -08:00
Leonardo de Moura
5d825483c4
refactor(library/init/meta/interactive): tactic.interactive.types ==> interactive.types
...
Motivation: we will use auto-quotation for other tactic monads
2016-12-30 18:06:41 -08:00
Leonardo de Moura
bb37b33237
fix(library/tactic/ac_tactics): binary.left_comm ==> left_comm
2016-12-28 21:23:07 -08:00
Leonardo de Moura
b5c1b429e7
feat(library/tactic/ac_tactics): add ac_manager helper class
2016-12-27 17:57:56 -08:00
Leonardo de Moura
9b35adfc8c
feat(library/tactic/congruence/congruence_closure): add support for constructor equalities
2016-12-25 12:47:17 -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
b1b694a532
fix(library/tactic/congruence/congruence_closure): bugs, and add basic cc tactic
2016-12-23 19:30:45 -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
cc077554b5
fix(library/tactic/change_tactic): use id_locked in the change tactic to create checkpoint
...
closes #1260
2016-12-21 11:29:03 -08:00
Leonardo de Moura
6577cc87a3
feat(library): add pre_monad
...
closes #1235
2016-12-08 12:48:55 -08:00
Leonardo de Moura
98fbe76f30
feat(library/comp_val): add mk_string_val_ne_proof
2016-11-23 13:19:24 -08:00
Leonardo de Moura
680bab8bb8
feat(library/comp_val): add mk_fin_val_ne_proof and mk_char_val_ne_proof
2016-11-23 10:25:04 -08:00
Leonardo de Moura
f4b1413cee
feat(library/comp_val): add mk_nat_val_lt_proof and mk_nat_val_le_proof
2016-11-22 15:14:10 -08:00
Leonardo de Moura
227e16ea6b
feat(library): add mk_nat_val_ne_proof
...
Procedure for building an efficient disequality proof for natural
number values encoded in binary.
2016-11-19 17:02:48 -08:00
Leonardo de Moura
88d2f07567
feat(frontends/lean/tactic_notation): switch to proof-term mode when calc/suppose/assume/have/show occurs in a tactic block
2016-11-18 16:57:31 -08:00
Leonardo de Moura
e16e9880f7
chore(library/system): enforce Lean naming conventions IO ==> io
2016-11-17 11:27:37 -08:00
Leonardo de Moura
3628870121
feat(library/tactic/vm_monitor): extend VM introspection API
2016-11-15 15:05:46 -08:00
Leonardo de Moura
fffe69fdf9
feat(library/vm,library/tactic/vm_monitor): use optionT to define vm monad
2016-11-14 16:13:56 -08:00
Leonardo de Moura
7232e3a076
feat(library/vm/vm): invoke debugger (aka vm_monitor)
2016-11-14 14:45:49 -08:00
Leonardo de Moura
205d524409
refactor(library/tactic/simplify): delete old simplifier
2016-10-19 14:03:14 -07:00
Leonardo de Moura
4d52de6f33
refactor(library/tactic/simplify): add simplify subclasses, and use new simplifier at nested
2016-10-18 16:18:25 -07:00
Leonardo de Moura
7465529445
feat(library/tactic): 'eval_expr' tactic skeleton
2016-10-03 16:26:28 -07:00
Leonardo de Moura
c0022253a7
feat(frontends/lean/tactic_notation): allow lemmas to be removed
2016-09-30 19:53:51 -07:00
Leonardo de Moura
fd6dc8154a
feat(library/init/meta/interactive): add interactive tactics
2016-09-30 19:02:45 -07:00
Leonardo de Moura
23ce2b0587
feat(frontends/lean/tactic_notation, library/init/meta/interactive): add "interactive" versions of define/assert/definev/assertv/note tactics
2016-09-29 18:48:32 -07:00
Leonardo de Moura
c6ec659bf5
feat(frontends/lean): improve 'begin...end' blocks
2016-09-27 13:34:11 -07:00
Leonardo de Moura
c6609543d0
chore(library/init): minor changes
2016-09-27 07:23:51 -07:00
Leonardo de Moura
bbf21b4e65
feat(frontends/lean/begin_end_block): auto-quote identifiers
2016-09-25 17:25:21 -07:00
Leonardo de Moura
8b132c758a
feat(frontends/lean/begin_end_block): add basic auto-quotation
2016-09-25 17:03:12 -07:00
Leonardo de Moura
97261fcc48
feat(frontends/lean): add very basic 'begin ... end' block support
2016-09-24 21:27:27 -07:00
Leonardo de Moura
9ee553945c
feat(frontends/lean/brackets): set_of notation
2016-09-24 13:47:41 -07:00
Leonardo de Moura
f00e6c0a96
feat(frontends/lean): anonymous instances
...
The instance name is synthesized automatically.
2016-09-23 13:34:34 -07:00
Leonardo de Moura
973bc5f1d6
feat(frontends/lean): add notation for 'sep'
2016-09-21 16:29:59 -07:00
Leonardo de Moura
c0ff9967af
feat(frontends/lean): add basic notation for collections
2016-09-21 16:20:57 -07:00
Leonardo de Moura
5e5285ee67
refactor(library): rename pr1/pr2 ==> fst/snd
2016-09-21 09:48:39 -07:00
Sebastian Ullrich
5e3e54e208
feat(library/tactic/user_attribute): Support pure function caching for user-defined attributes
2016-09-12 10:38:48 -07:00
Leonardo de Moura
6ac64c7250
feat(library/equations_compiler/elim_match): make process_transport more robust
2016-09-11 16:21:15 -07:00
Daniel Selsam
b0c5744eea
feat(inductive_compiler): support for mutually inductive types
2016-09-10 14:22:27 -07:00
Leonardo de Moura
dcc314c109
feat(library/noncomputable): improve is_noncomputable
2016-09-08 14:02:23 -07:00
Leonardo de Moura
029766495b
feat(library/equations_compiler/util): try to improve performance of lemma generation
...
There are still performance problems. Lemma generation is fine, but the
kernel is timing out when checking the lemma. We need to provide hints
to the kernel to avoid the performance problem.
2016-09-03 13:24:44 -07:00