Leonardo de Moura
ae06844f57
chore(library/init/meta): remove unnecessarily '| failed' annotations
...
tactic and smt_tactic are instaces of monad_fail
2017-02-05 20:12:42 -08:00
Leonardo de Moura
55aa2023f4
feat(frontends/lean): add support for monad_fail type class in 'do' blocks
2017-02-05 20:09:08 -08:00
Leonardo de Moura
8b662d19ac
feat(library/init/category/monad_fail): add monad_fail type class
2017-02-05 18:46:29 -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
30a1876fc8
feat(library/init/meta): add add_aux_decl and abstract tactics
2017-02-05 16:00:47 -08:00
Leonardo de Moura
1eb771f5a1
chore(library/init/meta/async_tactic): missing copyright
2017-02-05 14:47:43 -08:00
Gabriel Ebner
95068e4e79
feat(library/sorry): make sorry a macro
2017-02-05 14:01:03 +01:00
Rob Lewis
d18a47b588
feat(tactic): add tactic_format instances
2017-02-04 15:30:55 -08:00
Leonardo de Moura
b28ed2453e
feat(frontends/lean/definition_cmds): allow meta recursive definitions without recursive equations
2017-02-04 13:44:05 -08:00
Leonardo de Moura
aff5a2dd37
fix(library/init/meta): bug introduced 9bee8ce36d
2017-02-03 17:01:46 -08:00
Leonardo de Moura
2640d3085b
fix(library/init/meta/interactive): name resolution problems in parametric sections
2017-02-03 14:04:59 -08:00
Leonardo de Moura
9bee8ce36d
fix(frontends/lean/elaborator): thunk gadget should not be considered in patterns
...
The new test demonstrates the problem.
2017-02-02 17:28:03 -08:00
Leonardo de Moura
bb9a0c79f4
feat(frontends/lean/builtin_exprs): better syntax for quoted terms with type ascription
2017-02-01 12:49:38 -08:00
Leonardo de Moura
6e7929252f
feat(frontends/lean, library/init): add 'thunk' gadget
...
We can now write
trace "hello" t
instead of
trace "hello" (fun _, t)
2017-01-31 18:41:59 -08:00
Leonardo de Moura
7cc31835e4
refactor(library/init/meta/fun_info): cleanup fun_info API
2017-01-31 18:01:54 -08:00
Leonardo de Moura
49a0d13c50
feat(library/init/coe): add coercion from A to (option A)
...
A little hack is used to make sure type class resolution will not enter
in an infinite loop.
2017-01-31 17:45:41 -08:00
Leonardo de Moura
920e845b84
refactor(library/init/meta/congr_lemma): cleanup congr_lemma API
2017-01-31 16:46:13 -08:00
Leonardo de Moura
2b56040499
fix(library/init/propext): Type => Sort
2017-01-30 19:17:57 -08:00
Leonardo de Moura
4a2ffefdaf
fix(library/init/wf): wf eliminators should be able to eliminate into Prop and Type
2017-01-30 19:14:43 -08:00
Leonardo de Moura
d3db3661af
refactor(library/init/core): simpler has_sep type class with out_param
2017-01-30 18:54:56 -08:00
Leonardo de Moura
04a8518104
refactor(library/init/core): simpler has_insert type class with out_param
2017-01-30 18:50:21 -08:00
Leonardo de Moura
f176c272b4
refactor(library/init/core): simpler has_mem type class with out_param
2017-01-30 18:43:05 -08:00
Leonardo de Moura
5da8b205b9
feat(library/type_context, frontends/lean/elaborator): type classes with output parameters
2017-01-30 18:32:54 -08:00
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
41bf46dbba
chore(library/init): adjust Sort vs Type in definitions
2017-01-30 12:50:18 -08:00
Leonardo de Moura
3b38f71f11
fix(library,tests/lean): fix run/interactive tests, and problems in the standard library due to the new interpretation for Type
...
We had to change subtype to use Sort since the axiom
strong_indefinite_description uses it.
see #1341
2017-01-30 11:54:00 -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
77a9feaf70
refactor(frontends/lean): PType ==> Sort
...
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
Gabriel Ebner
3804722b91
fix(init/meta/decl_cmds): avoid blocking
2017-01-28 08:27:23 +01:00
Gabriel Ebner
e839080834
feat(init/meta/async_tactic): add tactic to prove subgoals in a different task
2017-01-28 08:27:23 +01:00
Gabriel Ebner
952f444710
feat(init/meta/task): allow task creation from VM
2017-01-28 08:27:23 +01:00
Gabriel Ebner
5fdc737dfc
feat(library/tactic): store name of current declaration in tactic_state
2017-01-28 08:27:19 +01: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
93ba77f8da
chore(library/data): rename tuple => vector
2017-01-26 22:11:10 -08:00
Leonardo de Moura
b1d097e63a
feat(library/init/meta): add 'delta' tactic for applying delta reduction
...
closes #1331
2017-01-26 19:04:07 -08:00
Leonardo de Moura
3f124f1a15
feat(library/init/logic): add decidable instance for ite and dite
2017-01-26 18:42:46 -08:00
Leonardo de Moura
08a0924fe3
fix(library/data/bitvec): typo
2017-01-25 18:41:32 -08:00
Joe Hendrix
641ccbc846
chore(library/data): remove (list/tuple).firstn in favor of taken
2017-01-25 18:39:54 -08:00
Leonardo de Moura
552ca66e9e
feat(library/init/meta/pexpr): expose low level function mk_placeholder
2017-01-25 15:32:50 -08:00
Leonardo de Moura
258fb522d3
feat(library/tactic/smt): add generation heuristic to control matching loops
2017-01-24 22:46:45 -08:00
Leonardo de Moura
0ba60e62d7
feat(kernel/quotient/quotient): make quotient module robust against users that define their own prelude's
...
Before this commit, an user could define their own prelude and change
the types of quot, quot.mk, quot.lift or quot.ind.
By doing that, they could prove false.
This commit prevents this kind of abuse.
It also modifies the definition of `quot` and avoids the `setoid`
dependency.
The previous `quot` type is now called `quotient`, and it is defined
using the new `quot` type provided by the kernel.
See discussion at #1330
2017-01-24 15:59:38 -08:00
Leonardo de Moura
ac6bfce01c
feat(library/tactic/smt/congruence_closure): improve propagation for beta reduction in the congruence closure module
2017-01-24 12:09:37 -08:00
Leonardo de Moura
6d12de6339
refactor(library/init/meta/smt): use default value for config structures
2017-01-23 14:18:06 -08:00
Leonardo de Moura
778d5382f6
refactor(library/init/meta/simp_tactic): use default field values at simplify_config
2017-01-23 10:22:48 -08:00
Leonardo de Moura
8ef21040d6
chore(library/init/algebra/order): remove leftover
2017-01-22 21:31:04 -08:00
Leonardo de Moura
71a7a7f466
feat(frontends/lean): add default field values
2017-01-22 21:25:49 -08:00
Leonardo de Moura
f7edf601c8
fix(library/init/data/nat/lemmas): avoid bad patterns in nat sub ematch lemmas
...
The attribute [ematch_lhs] instructs Lean to use the left-hand-side of
the conclusion as a pattern.
2017-01-22 19:48:01 -08:00
Leonardo de Moura
4b11afcb46
feat(library/init/meta/interactive): add doc strings
2017-01-22 16:41:27 -08:00
Leonardo de Moura
3516773644
chore(library/init): minor fixes
2017-01-22 14:20:48 -08:00