Rob Lewis
958add9ef8
feat(library/norm_num): fix numeral normalization to work on new numeral structure; add support for multiplication
2015-11-08 14:04:56 -08:00
Leonardo de Moura
08c061e1fa
refactor(library/data/set): remove [reducible]
annotation from set operations
2015-11-08 14:04:56 -08:00
Leonardo de Moura
6df31d3406
refactor(library/data/nat/basic): mark some theorems as protected to avoid overloading
2015-11-08 14:04:56 -08:00
Leonardo de Moura
4e78e35f77
fix(tests/lean): adjust remaining tests to changes in the standard library
2015-11-08 14:04:56 -08:00
Leonardo de Moura
29763190ad
fix(tests/lean): adjust some tests to changes in the standard library
2015-11-08 14:04:56 -08:00
Leonardo de Moura
81618e30f3
fix(tests/lean/run): adjust some tests to changes in the standard library
2015-11-08 14:04:56 -08:00
Leonardo de Moura
b3c89070e3
fix(tests/lean): test output
2015-10-13 09:57:58 -07:00
Sebastian Ullrich
dbfebd5409
feat(frontends/lean/scanner): add more checks to read_quoted_symbol
2015-10-13 09:52:35 -07:00
Leonardo de Moura
e4f0f6a9b4
feat(library): numeral normalization skeleton
2015-10-08 12:49:12 -07:00
Leonardo de Moura
1c4dea9941
fix(tests/lean): adjust tests to reflect changes in the pretty printer
2015-09-30 17:42:07 -07:00
Leonardo de Moura
542a998f0e
fix(tests/lean): adjust tests to reflect changes in the HoTT library
2015-09-25 09:46:51 -07:00
Leonardo de Moura
28a5ca5809
fix(frontends/lean): fixes #830
2015-09-18 07:51:02 -07:00
Leonardo de Moura
68dc39c106
fix(tests/lean/run/rewriter12): broken test, now ^[
is a token
2015-09-16 08:37:43 -07:00
Leonardo de Moura
df3100d2cd
fix(library/local_context): bug in abstract_locals procedure
2015-09-12 17:17:13 -07:00
Leonardo de Moura
1fdbd681cc
feat(frontends/lean/builtin_exprs): name hypothesis in suffices
...
closes #817
2015-09-03 16:09:39 -07:00
Leonardo de Moura
1dc1574ad4
fix(frontends/lean/parse_table): do not add 'no_info' annotation in tactic expressions
2015-09-02 20:51:06 -07:00
Leonardo de Moura
634c0b5e9d
feat(library/tactic,frontends/lean): propagate new options back to elaborator
2015-09-02 20:34:14 -07:00
Leonardo de Moura
44c6e92a64
fix(tests/lean): notation ℕ is now defined in the top-level
2015-09-01 14:58:14 -07:00
Leonardo de Moura
c84e886c7b
fix(frontends/lean/notation_cmd): fixes #808
...
This commit and 2b1d2c fixes #808
2015-08-31 18:05:58 -10:00
Leonardo de Moura
08169c5ac2
fix(library/unifier): fixes #809
...
Daniel is correct when he says the interaction between choice
case-splits, delta case-splits, and coercions can be subtle.
I believe the following condition
https://github.com/leanprover/lean/blob/master/src/frontends/lean/elaborator.cpp#L111
reduces counter-intuitive behavior. Example, the coercion should not
influence the resulting type.
BTW, by removing this condition, many files in the library broke when I
tried to compile from scratch
make clean-olean
make
I used the following workaround. Given a delta-delta constraint
f a =?= f b
If the terms are types, and no case-split will be performed, then
the delta-delta constraint is eagerly solved.
In principle, we don't need the condition that the terms are types.
However, many files break if we remove it. The problem is that many files in the standard
library are abusing the higher-order unification procedure. The
elaboration problems are quite tricky to solve.
I use the extra condition "the terms are types" because usually if they
are, "f" is morally injective, and we don't really want to unfold it.
Note that the following two cases do not work
check '{1, 2, 3}
check insert 1 (insert 2 (insert 3 empty))
Well, they work if we the num namespace is open, and they are
interpreted as having type (finset num)
2015-08-31 17:59:30 -10:00
Leonardo de Moura
2b1d2c21ad
fix(frontends/lean/util): bug when parsing priorities and numerals are overloaded
2015-08-31 15:08:21 -10:00
Leonardo de Moura
a3c404ac3b
feat(library/tactic/apply_tactic): do not report elaboration failure in apply tactic when proof_state.report_failure() is false
2015-08-21 15:45:52 -07:00
Leonardo de Moura
87349dc355
feat(frontends/lean/token_table): add 'proposition' keyword
2015-08-19 08:05:31 -07:00
Leonardo de Moura
3a72cd9621
fix(frontends/lean): rename multiword keyword "suffices to show" to "suffices"
2015-08-18 17:57:53 -07:00
Leonardo de Moura
3ce8c5d6f7
feat(frontends/lean): add "suffices to show A, from B, C" construct
2015-08-18 17:04:38 -07:00
Leonardo de Moura
9fcf3d4675
fix(tests/lean/extra): discrepancy between tests output when compiling Lean with IGNORE_SORRY
2015-08-18 12:42:22 -07:00
Leonardo de Moura
21c41f50ea
fix(frontends/lean/elaborator): fixes #803
2015-08-17 14:56:41 -07:00
Leonardo de Moura
b07a364d2f
feat(frontends/lean/parser): process multiple parsing actions
...
closes #800
2015-08-17 09:42:10 -07:00
Leonardo de Moura
b0dbc31d4b
test(tests/lean/list_vect_numerals): add test mixing nat,int,real,list,vector
2015-08-16 18:54:14 -07:00
Leonardo de Moura
ea04414058
feat(frontends/lean): allow user to overload notation containing foldr/foldl and/or scoped expressions
...
see new tests for a summary of new features
see issue #800
2015-08-16 18:24:30 -07:00
Leonardo de Moura
eb8f586dba
fix(library/normalize): fixes #801
2015-08-16 14:22:02 -07:00
Leonardo de Moura
5a6a4b45c1
fix(library/definitional/equations): fixes #796
2015-08-14 14:39:23 -07:00
Leonardo de Moura
d2eb99bf11
refactor(library/logic): move logic/choice.lean to init/classical.lean
...
choice axiom is now in the classical namespace.
2015-08-12 18:37:33 -07:00
Leonardo de Moura
cb9830beaf
refactor(library/logic/choice): move prop_decidable instance into namespace 'classical'
2015-08-12 17:06:15 -07:00
Leonardo de Moura
b4024982a2
refactor(library/data): move vector as indexed family to examples folder
2015-08-12 15:05:14 -07:00
Leonardo de Moura
602626803b
fix(frontends/lean/builtin_cmds): 'print axioms' and theorem queue
2015-08-11 21:08:45 -07:00
Leonardo de Moura
5d8d226640
fix(frontends/lean/parser): add support for decimals
...
Decimal numbers are notation for rationals.
If rat.of_num is not available, then an error is generated.
closes #793
2015-08-11 18:44:48 -07:00
Leonardo de Moura
66a59d5b51
feat(frontends/lean/util): remove hack that overrides priority namespace
...
closes #789
2015-08-11 18:01:40 -07:00
Leonardo de Moura
0b8f57841a
feat(frontends/lean/decl_cmds): closes #791
2015-08-11 17:53:33 -07:00
Jeremy Avigad
305f72bf4f
fix(tests/lean): fix three tests broken by setext renaming
2015-08-09 22:14:25 -04:00
Leonardo de Moura
582dbecfd0
feat(library,hott): add notation T1 : T2
as syntax sugar for (focus (T1; all_goals T2))
...
closes #775
2015-08-08 10:16:25 -07:00
Leonardo de Moura
1f34c72192
fix(frontends/lean/parser): fixes #770
2015-08-08 09:48:31 -07:00
Leonardo de Moura
dc2e702373
feat(library/unifier): generate approximate solution for universe constraints of the form (max u ?m =?= max u v)
...
closes #777
2015-08-08 09:29:59 -07:00
Leonardo de Moura
6c5832a564
feat(frontends/lean/decl_cmds): allow recursive examples
...
closes #774
2015-08-08 08:26:25 -07:00
Leonardo de Moura
06f20694c8
fix(frontends/lean/builtin_exprs): fixes #768
2015-08-08 04:20:17 -07:00
Leonardo de Moura
d46dbce86e
feat(library/tactic/tactic): apply substitution in 'then' combinator
...
closes #778
2015-08-08 03:42:21 -07:00
Floris van Doorn
7f76d7e648
fix(tests): update test
2015-08-07 13:34:41 -07:00
Leonardo de Moura
5568085ab9
fix(frontends/lean/elaborator): closes #771
...
Produce nicer error message when type/goal is a metavariable and
universe metavariables have already been instantiated with universe
parameters.
2015-08-07 13:29:22 -07:00
Leonardo de Moura
6a079fdd2d
fix(library/tactic/exact_tactic): fixes #779
2015-08-07 13:29:22 -07:00
Leonardo de Moura
f21647899f
feat(frontends/lean/builtin_exprs): rename 'show' hidden name to 'this'
...
This is useful if 'show' is recursive
2015-08-07 13:29:21 -07:00
Floris van Doorn
11b1f416f6
feat(nat): add unfold attributes to add, mul, sub and of_num in namespace nat_esimp in both libraries
2015-08-04 13:23:20 +02:00
Floris van Doorn
7a780b1b60
feat(hott): various minor changes in the HoTT library
2015-08-04 13:01:11 +02:00
Leonardo de Moura
0309a1e131
fix(tests/lean/extra/show_goal_bag): adjust test to recent changes in the standard library
2015-08-04 06:52:20 +02:00
Leonardo de Moura
1f304ad4b9
fix(frontends/lean/pp): pretty printing 'binder'
...
This commit also replaces many occurrences of 'binders' with 'binder'.
2015-07-31 11:27:38 -07:00
Leonardo de Moura
656b642c4a
fix(frontends/lean): identifier size when using unicode
...
see issue #756
2015-07-30 11:32:24 -07:00
Leonardo de Moura
cc4f18c062
feat(frontends/lean): add "--info" command line option for extracting identifier/keyword information
...
see issue #756
2015-07-30 10:18:03 -07:00
Leonardo de Moura
be61fb0566
feat(frontends/lean/elaborator): add "noncomputable theory" command, display "noncomputable" when printing definitions
...
When the command "noncomputable theory" is used, Lean will not sign an
error when a noncomputable definition is not marked as noncomputable
2015-07-29 17:54:35 -07:00
Leonardo de Moura
b3707ab54a
feat(library/tactic/unfold_rec): fixes #753
2015-07-29 17:13:02 -07:00
Leonardo de Moura
ed41a01a51
fix(frontends/lean/elaborator): fixes #755
2015-07-29 16:41:30 -07:00
Leonardo de Moura
bbd6946a15
refactor(library/logic/axioms): we have only one extra axiom
2015-07-29 13:36:23 -07:00
Leonardo de Moura
6dbcf86fd4
feat(library/logic/axioms): use diaconescu to prove em
...
With the new "noncomputable" feature we can use Hilbert's choice without
being concerned it may accidentaly "leak" inside definitions we don't
want to use it.
2015-07-29 13:01:07 -07:00
Leonardo de Moura
0bda39c8ac
feat(frontends/lean): check for noncomputability when moving theorems from theorem_queue to environment
2015-07-29 13:01:07 -07:00
Leonardo de Moura
69ead0ddd8
feat(frontends/lean/decl_cmds): reject unnecessary "noncomputable" annotations
2015-07-29 13:01:07 -07:00
Leonardo de Moura
74be3031b1
feat(frontends/lean/decl_cmds): sign an error if "noncomputable" keyword is used in the HoTT library or with non-definitions
2015-07-29 13:01:06 -07:00
Leonardo de Moura
308af87b69
feat(library): add 'noncomputable' keyword for the standard library
2015-07-28 21:56:35 -07:00
Leonardo de Moura
7e8a394caf
chore(tests/lean): fix style and adjust tests
2015-07-28 18:15:25 -07:00
Leonardo de Moura
b81d4d50f1
feat(frontends/lean/bultin_cmds): add 'print axioms <declname>' command that prints axioms a giving declaration depends on
2015-07-28 18:15:25 -07:00
Leonardo de Moura
80e3da0526
fix(library/util): fixes #751
2015-07-28 16:30:20 -07:00
Leonardo de Moura
8ee1d35bed
fix(tests/lean/unfold_crash): fixed regression test for bug reported by Rob
2015-07-28 12:51:42 -07:00
Leonardo de Moura
cfa9412f96
fix(frontends/lean): "show goal" localization, add "position", support "by tactic"
2015-07-28 12:48:12 -07:00
Leonardo de Moura
0dc8dc999e
fix(library/tactic/rewrite_tactic): crash when trying to unfold constructor
2015-07-28 12:43:56 -07:00
Leonardo de Moura
08b23d8b4f
test(tests/lean/extra): add test for "show goal" feature
2015-07-27 21:03:16 -07:00
Leonardo de Moura
a3b570c852
test(tests/lean/extra): test for Soonho
2015-07-27 19:32:27 -07:00
Leonardo de Moura
8c06803f54
test(tests/lean): add regression for issue #737
2015-07-27 07:59:18 -07:00
Leonardo de Moura
f7440ff068
fix(tests/lean): adjust tests to reflect changes in the standard library
2015-07-24 09:59:49 -07:00
Leonardo de Moura
bcf057f4f3
feat(frontends/lean): display '[congr]' attribute when printing theorems
2015-07-23 18:52:59 -07:00
Leonardo de Moura
3e6b80d38c
feat(library/util): disable local constant purification when pretty printing goals
...
This feature generates confusion.
2015-07-23 18:52:59 -07:00
Leonardo de Moura
f1a19a10c4
fix(library/util): incorrect hypothesis renaming when pretty printing goals
2015-07-23 18:52:59 -07:00
Leonardo de Moura
e221d38790
feat(library/tactic/assert_tactic): allow duplicate names for hypotheses in assert tactic
2015-07-23 18:52:59 -07:00
Leonardo de Moura
e0209a1532
feat(frontends/lean): better error localization for 'have'-expressions in tactic mode
2015-07-23 18:52:59 -07:00
Leonardo de Moura
faab1e449f
fix(tests/lean/rw_set3): update test to reflect changes in the standard library
2015-07-23 18:52:59 -07:00
Leonardo de Moura
5f4576a7f7
test(tests/lean): add test for '[congr]' attribute validation
2015-07-23 18:52:59 -07:00
Leonardo de Moura
844caf32e4
feat(frontends/lean/bultin_cmds): add 'print [congr]' command for displaying active congruence rules
2015-07-23 18:52:59 -07:00
Leonardo de Moura
933f056fff
feat(library/simplifier): add API for extracting simplification rules defined in a given namespace
2015-07-22 18:47:56 -07:00
Leonardo de Moura
8085123119
refactor(library/simplifier): rename 'rewrite_rule' to 'simp_rule'
2015-07-22 10:39:30 -07:00
Leonardo de Moura
092c8d05b9
feat(frontends/lean,library): rename '[rewrite]' to '[simp]'
2015-07-22 09:01:42 -07:00
Leonardo de Moura
23dd47d27f
fix(tests/lean): adjust tests to recent changes to the standard library
2015-07-19 21:32:42 -07:00
Leonardo de Moura
5112232d6d
fix(tests/lean/run/finset): adjust test to recent changes to the
...
standard library
2015-07-19 11:53:21 -07:00
Leonardo de Moura
3ab0e07ba9
feat(frontends/lean): add simp tactic frontend stub
...
This commit also removes the fake_simplifier. It doesn't work anymore
because simp is now a reserved word.
2015-07-14 09:54:53 -04:00
Leonardo de Moura
589f9df103
fix(tests/lean): adjust tests to reflect recent changes in the standard library
2015-07-13 21:46:09 -04:00
Leonardo de Moura
267545ca0c
feat(frontends/lean): parse 'with_options' tactical
...
see issue #492
2015-07-13 19:13:41 -04:00
Leonardo de Moura
f8d472c9f1
feat(frontends/lean/parse_rewrite_tactic): change the semantics of rewrite[↑f] when f is recursive
...
After this commit it behaves like 'unfold f'.
That is, it will unfold f even if it fails to fold recursive
applications. Now, only 'esimp[f]' will not unfold f-applications when
it cannot fold the recursive applications.
This commit also closes #692 . It is part of a series of commits that
addresses this issue.
closes #692
2015-07-12 13:20:21 -04:00
Leonardo de Moura
4c0a656ecc
fix(library/tactic/unfold_rec): support indexed families + brec_on at unfold_rec
...
see issue #692
2015-07-12 12:45:05 -04:00
Leonardo de Moura
7fa5c3e5da
feat(library/tactic/unfold_rec): take '[recursor]' annotations into account at unfold_rec
2015-07-12 11:33:40 -04:00
Leonardo de Moura
f0e3eef38a
test(tests/lean/unfold_rec2): add example from #692
2015-07-11 19:45:27 -04:00
Leonardo de Moura
8e8e08cfe7
feat(library/tactic): use occurrence object in unfold tactic family
2015-07-11 18:53:45 -04:00
Leonardo de Moura
554a42b407
fix(library/tactic/unfold_rec): add annother brec pattern that should be checked in the unfold recursive definition tactic
2015-07-10 22:16:23 -04:00
Leonardo de Moura
a9515ac7a4
feat(library/tactic/rewrite_tactic): try to fold nested recursive applications after unfolding a recursive function
...
See issue #692 .
The implementation still has some rough spots.
It is not clear what the right semantic is.
Moreover, the folds in e_closure could not be eliminated automatically.
2015-07-08 21:19:18 -04:00
Leonardo de Moura
26574e29a9
feat(library/normalize,frontends/lean): allow multiple arguments in [unfold] hint
...
closes #693
2015-07-07 18:01:57 -07:00
Leonardo de Moura
a27b20cd9c
feat(frontends/lean/notation_cmd): allow local notation to override reserved notation
...
closes #712
2015-07-07 17:30:46 -07:00
Leonardo de Moura
4b1b3e277f
feat(frontends/lean): rename '[unfold-c]' to '[unfold]' and '[unfold-f]' to '[unfold-full]'
...
see issue #693
2015-07-07 16:37:06 -07:00
Leonardo de Moura
b0c56273e2
fix(frontends/lean/elaborator): fixes #724
2015-07-06 15:19:19 -07:00
Leonardo de Moura
7e0844a9e6
fix(tests): to reflect recent changes in the standard library
2015-07-06 15:05:01 -07:00
Leonardo de Moura
c843690d27
fix(frontends/lean/elaborator): fixes #719
2015-07-03 12:37:28 -07:00
Leonardo de Moura
aa338f6002
test(tests/lean/run): add test showing new coercion module addresses issue #668
2015-07-01 16:41:19 -07:00
Leonardo de Moura
4ae9f3ea81
feat(library/coercion): new coercion manager
...
closes #668
2015-07-01 16:32:34 -07:00
Leonardo de Moura
cf574d0127
feat(library): assign priorities to notation declarations in the standard library
...
Now, even if the user opens the namespaces in the "wrong" order, the
notation + coercions will behave as expected.
2015-06-30 17:38:13 -07:00
Leonardo de Moura
cabe30ba71
feat(frontends/lean): allow user to assign priorities to notation declarations
2015-06-30 17:10:27 -07:00
Leonardo de Moura
0fc2efe88e
fix(library/tactic/rewrite_tactic): fixes #702
2015-06-28 20:37:17 -07:00
Leonardo de Moura
95720b1670
fix(frontends/lean/elaborator): fixes #687
2015-06-28 19:58:57 -07:00
Leonardo de Moura
ecfc01b2d0
test(tests/lean/run): add test for <d
notation
...
see issue #695
remark: we have to fix the tutorial the ASCII notation for fold is `<d`
instead of `<D`
2015-06-28 13:10:15 -07:00
Leonardo de Moura
1b864a838f
fix(library/tactic/induction_tactic.cpp): condition for checking whether 'induction' tatic is applicable or not
...
fixes #690
2015-06-28 13:07:02 -07:00
Leonardo de Moura
2f75768243
feat(library/tactic/rewrite_tactic): fail when nothing is rewritten
...
fixes #686
2015-06-28 12:05:00 -07:00
Leonardo de Moura
d1eaa7bcda
feat(frontends/lean/parse_rewrite_tactic): accept trailing comman in rewrite tactic
...
see issue #695
2015-06-28 11:45:30 -07:00
Leonardo de Moura
4a4ef48344
fix(frontends/lean/parse_rewrite_tactic): fixes #691
2015-06-28 11:28:05 -07:00
Leonardo de Moura
869ad261c5
fix(frontends/lean/elaborator): fixes #689
2015-06-27 16:19:38 -07:00
Leonardo de Moura
97b3fd45ce
fix(library/logic/axioms/prop_decidable): fixes #704
2015-06-26 19:14:36 -07:00
Leonardo de Moura
2aa64034df
fix(tests/lean): adjust tests to reflect changes in the elaboration process
2015-06-26 17:18:30 -07:00
Floris van Doorn
9ef1ae0848
fix(tests): update tests to reflect the change of notation from \~ to ~
2015-06-25 22:55:05 -04:00
Leonardo de Moura
1b414d36e7
refactor(library/init): define prod as an inductive datatype
...
Motivation: prod is used internally in the definitional package.
If we define prod as a structure, then Lean will tag pr1 and pr2 as
projections. This creates problems when we add special support for
projections in the elaborator. The heuristics avoid some case-splits
that are currently performed, and without them some files break.
2015-06-25 17:59:06 -07:00
Floris van Doorn
fa1979c128
feat(datatypes): let the type of unit be the lowest non-Prop universe
...
The definitional package (brec_on and cases_on) now use poly_unit instead of unit
closes #698
2015-06-25 17:33:46 -07:00
Leonardo de Moura
a4c0699e81
feat(library/tactic/constructor_tactic): restore 'constructor' tactic old semantics, add 'fconstructor' tactic
...
See issue #676
Add new test demonstrating why it is useful to have the old semantics
for 'constructor'
2015-06-17 23:48:54 -07:00
Leonardo de Moura
bf71d9f342
fix(library/tactic/rewrite_tactic): fixes #682
2015-06-17 18:49:02 -07:00
Leonardo de Moura
ce8f2a1674
feat(library/class): allow any constant to be marked as a class
...
closes #679
2015-06-17 16:26:45 -07:00
Leonardo de Moura
9e6e406f73
feat(frontends/lean): add '#compose' command for testing composition manager
2015-06-17 14:42:25 -07:00
Leonardo de Moura
0ae24faae3
feat(library/tactic/constructor_tactic): use 'fapply' in 'constructor' tactic
...
closes #676
2015-06-16 12:03:31 -07:00
Leonardo de Moura
0dc674e350
fix(tests/lean/630): adjust test to reflect changes in the standard library
2015-06-16 11:33:26 -07:00
Jeremy Avigad
a4a8253f50
refactor(library,hott,tests): rename succ_inj to succ.inj, add abbreviation eq_of_succ_eq_succ
2015-06-15 22:52:38 +10:00
Leonardo de Moura
d8620ef4c9
fix(kernel,library,frontends/lean): improve error messages
...
see #669
2015-06-14 19:44:00 -07:00
Leonardo de Moura
8a85e4ee87
feat(frontends/lean/builtin_cmds): improve print <id>
when <id>
is a not yet revealed theorem
...
We add a remark saying the command `reveal <id>` should be used to
access `<id>` definition.
2015-06-13 12:12:22 -07:00
Leonardo de Moura
591fb91f34
fix(frontends/lean/builtin_cmds): fixes #671
2015-06-13 11:35:03 -07:00
Leonardo de Moura
9fbf267a3f
feat(library/tactic/rewrite_tactic): when 'rewrite' step fails apply esimp and try again
...
closes #670
2015-06-12 19:48:58 -07:00
Leonardo de Moura
3d9b557cfd
feat(frontends/lean): allow the user to mark subterms that should be automatically abstracted into new definitions
...
closes #484
2015-06-12 17:49:26 -07:00
Leonardo de Moura
7bad9fe554
feat(library/error_handling/error_handling): set 'pp.beta' to false when displaying errors
...
see issue #669
2015-06-12 14:46:51 -07:00
Leonardo de Moura
69be4c720c
fix(library/tactic/subst_tactic): bug in 'subst' tactic
2015-06-12 12:11:44 -07:00
Leonardo de Moura
8aa634378e
fix(tests/lean): adjust tests to reflect changes in the standard library
2015-06-10 17:00:47 -07:00
Leonardo de Moura
0b335230d7
test(tests/lean): add test for eta at postprocessing
2015-06-10 16:33:27 -07:00
Leonardo de Moura
8b7dc4e03a
feat(frontends/lean): apply eta-reduction in postprocessing step
...
Perhaps, we should add an option to disable this new feature.
Remark: this commit makes commit 46d418a
redundant.
I'm keeping 46d418a
because we may retract this commit in the future.
2015-06-10 16:29:30 -07:00
Leonardo de Moura
4b91cfccff
feat(frontends/lean/builtin_exprs): make notation ( e : T )
builtin
...
In the previous approach, the following (definitionally equal) term was being generated
(fun (A : Type) (a : A), a) T e
2015-06-10 14:52:59 -07:00
Leonardo de Moura
cff7b7474a
test(tests/lean/run): add examples showing how to prove (using tactics) that direct_subterm relation is well-founded
...
see issue #347
2015-06-09 16:17:29 -07:00
Leonardo de Moura
1bffb89126
fix(library/algebra/function): lean was failing to infer that injective is a decidable predicate for finite types with decidable equality
...
This is an issue reported by Haitao.
2015-06-09 15:30:58 -07:00
Leonardo de Moura
2663c9ab9f
test(tests/lean/run): add test/example
...
add test/example that defines count_vars using tactics and recursors.
see #662 for original definition, and e3a0e62859
for the fix that
allows us to use recursive equations.
The recursive equations are compiled into recursors.
2015-06-09 14:50:15 -07:00
Leonardo de Moura
e3a0e62859
fix(library/unifier): try to generate approximate solution for flex-flex constraints before discarding them
...
fixes #662
2015-06-09 14:36:31 -07:00
Leonardo de Moura
627e05c9e6
fix(library/tactic/rewrite_tactic): improve krewrite
2015-06-08 16:46:28 -07:00
Leonardo de Moura
d6a483fe84
feat(library): add idx_metavar module
2015-06-08 16:02:37 -07:00
Leonardo de Moura
496189feed
feat(kernel/default_converter): cache failures for (f t =?= f s) heuristic
...
See item 4 at
https://groups.google.com/forum/?utm_medium=email&utm_source=footer#!msg/lean-discuss/oJXwW5wT2Ds/d1Dgr8B-pE0J
See also
https://github.com/leanprover/lean/pull/659
2015-06-08 10:41:30 -07:00
Leonardo de Moura
0e099b5fd8
feat(library/tactic/rewrite_tactic): apply beta&eta reduction before rewriting steps, add option 'rewrite.beta_eta' (default true) to control new feature.
2015-06-06 20:43:52 -07:00
Leonardo de Moura
1cbace9df6
feat(library/tactic/congruence_tactic): add congruence lemma generator
...
The generated congruence theorems ignore arguments that are subsingleton types.
2015-06-05 22:00:10 -07:00
Leonardo de Moura
7db84c7036
refactor(library/data): replace 'fin' with Haitao's 'less_than'
...
The commit also fixes vector to use the new definition.
2015-06-05 10:33:19 -07:00
Leonardo de Moura
c76d92284f
feat(library/pp_options): add 'pp.all' option
2015-06-05 08:41:46 -07:00
Floris van Doorn
7f5caab694
feat(nat): redefine le and lt in the standard library
2015-06-04 20:14:13 -04:00
Floris van Doorn
ff01774fd7
renaming(hit): rename type_quotient to quotient, and quotient to set_quotient
...
This renaming is because type_quotient is a nonstandard name. I've had a discussion with Egbert
Rijke, Steve Awodey and Dan Licata, and the consensus for a better name was 'quotient'. I had to
make changes in src/kernel/hits/hits.cpp, I renamed g_type_quotient* by g_hit_quotient* (to avoid
name clash the standard library quotient, although I don't know whether that name clash would
matter).
2015-06-04 20:14:13 -04:00
Jeremy Avigad
df69bb4cfc
feat(library/*): add theorems from Haitao on sets and functions, clean up
2015-06-04 11:55:25 -07:00
Leonardo de Moura
134740182d
fix(frontends/lean): fixes #652
2015-06-03 21:53:51 -07:00
Leonardo de Moura
68688ecdf6
fix(library/tactic/subst_tactic): in the standard mode, use dependent elimination in the subst tactic (when needed)
...
Before this commit, the subst tactic was producing an type incorrect
result when dependent elimination was needed (see new test for an example).
2015-06-03 17:36:04 -07:00
Leonardo de Moura
b2f8d2000c
fix(library/simplifier/rewrite_rule_set): avoid compiler specific behavior
2015-06-01 22:23:34 -07:00
Leonardo de Moura
d6997300f1
fix(library/private): use environment fingerprint to compute private decls "unique" identifier
...
fixes #648
2015-06-01 22:21:31 -07:00
Leonardo de Moura
4ace996057
fix(library/simplifier): bug in is_permutation_ceqv
2015-06-01 18:07:31 -07:00
Leonardo de Moura
0fbc944cdd
feat(frontends/lean): add '[rewrite]' attribute
2015-06-01 17:58:24 -07:00
Leonardo de Moura
b6fde68012
feat(frontends/lean/decl_cmds): avoid funny names when displaying error messages for "examples"
2015-06-01 15:35:28 -07:00
Leonardo de Moura
55608c9b9f
fix(frontends/lean/pp): bug in pp arrow
2015-05-31 17:21:37 -07:00
Leonardo de Moura
ca110012d8
feat(library/tactic): automate "generalize-intro-induction/cases" idiom
...
closes #645
2015-05-30 21:57:28 -07:00
Leonardo de Moura
e5a82ef516
feat(frontends/lean): add option for disabling "coercion lifting"
2015-05-30 17:07:42 -07:00
Leonardo de Moura
6f6848968d
feat(frontends/lean/coercion_elaborator): "coercion lifting" for backtracking case
...
closes #252
2015-05-30 16:44:26 -07:00
Leonardo de Moura
ea9c810fca
feat(frontends/lean/coercion_elaborator): implement "coercion lifting"
...
closes #644
2015-05-30 14:45:14 -07:00
Leonardo de Moura
6d2f37857d
feat(frontends/lean/builtin_cmds): add 'print [reducible]', 'print [irreducible]' and 'print [quasireducible]' commands
2015-05-29 16:47:29 -07:00
Leonardo de Moura
0ceedbe69e
fix(library/normalize): fixes #640
2015-05-29 15:58:59 -07:00
Leonardo de Moura
60ff057159
test(tests/lean): add missing test for issue #634
2015-05-29 15:13:43 -07:00
Leonardo de Moura
f48cdccd20
fix(frontends/lean/pp): abbreviation with parameters
...
closes #639
2015-05-29 15:13:31 -07:00
Leonardo de Moura
3b7b268e40
fix(frontends/lean/pp): fixes #634
...
trying again...
2015-05-29 14:07:38 -07:00
Leonardo de Moura
7f12401ea7
fix(frontends/lean/elaborator): save type information for 'obtain' declarations
2015-05-29 10:16:12 -07:00
Leonardo de Moura
7342f342a9
fix(frontends/lean/pp): fixes #634
2015-05-28 19:43:49 -07:00
Leonardo de Moura
d95c064a29
feat(library/simplifier/ceqv): add to_ceqv procedure
2015-05-27 16:35:56 -07:00
Leonardo de Moura
85409a59d3
feat(library/tactic/rewrite_tactic): add xrewrite and krewrite tactic variants
...
closes #511
2015-05-27 16:32:43 -07:00
Leonardo de Moura
dc6411b903
feat(library/inductive_unifier_plugin): restrict rule that was generating non-terminating behavior
...
see issue #632
2015-05-27 14:41:12 -07:00
Leonardo de Moura
ea43f3ea80
fix(frontends/lean/builtin_cmds): fixes #630
2015-05-26 22:19:42 -07:00
Floris van Doorn
a127a676eb
fix(tests): fix tests to reflect changes
2015-05-26 21:37:02 -07:00
Leonardo de Moura
0502f46f9b
fix(frontends/lean/scanner): another bug related to issue #626
2015-05-26 13:39:42 -07:00
Leonardo de Moura
25e41b9b09
fix(frontends/lean/scanner): fixes #626
2015-05-26 11:33:38 -07:00
Leonardo de Moura
a4e72e5262
test(tests/lean/run): add missing test
2015-05-25 17:02:23 -07:00
Leonardo de Moura
d0987eb3ac
feat(library/tactic): add 'subtvars' tactic
2015-05-25 16:36:44 -07:00
Leonardo de Moura
ab58e538a4
feat(frontends/lean/elaborator): hide auxiliary 'match' hypothesis during elaboration
2015-05-25 15:24:56 -07:00
Leonardo de Moura
a3f23d5233
feat(library/tactic): add improved 'subst' tactic
2015-05-25 15:03:59 -07:00
Leonardo de Moura
f13ca3cd9a
feat(library/tactic/contradiction_tactic): handle (h1 : p) and (h2 : not p) hypotheses in the contradiction tactic
2015-05-25 10:29:51 -07:00
Leonardo de Moura
88975927e6
fix(library/tactic/relation_tactics): beta-reduce goal before trying to extract head symbol
2015-05-24 18:56:35 -07:00
Leonardo de Moura
004ea80e65
fix(library/tactic/rewrite_tactic): apply beta reduction when selecting patterns
2015-05-24 18:44:30 -07:00
Jeremy Avigad
8bebd104ff
refactor(library/*): remove 'Module:' lines
2015-05-23 20:52:23 +10:00
Jeremy Avigad
db7bdce451
refactor(logic/funext.lean, algebra/function.lean): delete logic/funext, merge into algebra/function
2015-05-23 16:16:36 +10:00
Leonardo de Moura
b83b0c0017
fix(library/tactic/induction_tactic): fixes #619
2015-05-21 18:22:07 -07:00
Leonardo de Moura
89581cead7
fix(frontends/lean/parser): fixes #616
2015-05-20 23:33:41 -07:00
Leonardo de Moura
d6b72ef4d7
feat(library/tactic/induction_tactic): try available recursors until one works
...
closes #615
2015-05-20 23:23:05 -07:00
Leonardo de Moura
2164ba6f20
fix(library/tactic/induction_tactic): fixes #614
2015-05-20 23:14:11 -07:00
Leonardo de Moura
51d4644832
fix(library/tactic/induction_tactic): fixes #613
2015-05-20 22:26:50 -07:00
Leonardo de Moura
5508e4b132
feat(library/tactic/induction_tactic): type class inference for minor premises
...
closes #611
2015-05-20 20:48:33 -07:00
Leonardo de Moura
029f374a69
fix(library/tactic/induction_tactic): fixes #610
2015-05-20 20:28:02 -07:00
Leonardo de Moura
2d22bb8ea2
feat(frontends/lean/builtin_cmds): do not unfold proofs in the eval command
...
In the future, we should probably add an option for unfolding proofs.
2015-05-20 19:14:57 -07:00
Leonardo de Moura
d5da659be7
feat(frontends/lean/elaborator): include overload information in error messages
2015-05-20 17:21:27 -07:00
Leonardo de Moura
76c3757db7
feat(frontends/lean/elaborator): use custom normalizers for detecting whether there are coercions from/to a given type
...
closes #547
2015-05-20 16:12:12 -07:00
Leonardo de Moura
af3f0088f4
feat(frontends/lean): add 'override' (notation) command
2015-05-20 11:42:16 -07:00
Leonardo de Moura
8ce992b077
feat(frontends/lean/builtin_exprs): allow 'obtain' to be used in tactic mode
2015-05-19 16:26:02 -07:00
Leonardo de Moura
c133d26505
feat(frontends/lean/builtin_exprs): change how 'show' is processed in tactics
...
Unresolved placeholders were not being reported
2015-05-19 16:23:50 -07:00
Leonardo de Moura
78ee055de8
feat(library/tactic): add induction tactic with support for user defined recursors
...
closes #483
closes #492
2015-05-19 13:27:17 -07:00
Leonardo de Moura
6da2ba331f
fix(library/user_recursors): memory access violation
2015-05-19 11:07:31 -07:00
Leonardo de Moura
937d6ac7b6
fix(frontends/lean/pp): print notation produces incorrect output
...
fixes #604
2015-05-19 09:57:13 -07:00
Leonardo de Moura
e1c2340db2
fix(frontends/lean): consistent behavior for protected declarations
...
see https://github.com/leanprover/lean/issues/604#issuecomment-103265608
closes #609
2015-05-18 22:35:18 -07:00
Leonardo de Moura
c53b96c8d3
feat(frontends/lean): print all options for overloaded identifier
...
closes #608
2015-05-18 17:14:17 -07:00
Floris van Doorn
1c77122fd0
fix(tests): update tests because [unfold-c] attribute has been added to some definitions
2015-05-18 15:59:55 -07:00
Leonardo de Moura
19361f0196
feat(library/unifier): do not fire type class resolution as last resort when type contains metavariables
...
see discussion at #604
2015-05-18 15:45:23 -07:00
Leonardo de Moura
c61c049152
feat(library/user_recursors): generalize acceptable use-defined recursors
...
see issue #492
2015-05-18 14:21:10 -07:00
Leonardo de Moura
62082c72a8
fix(library/user_recursors): remove unnecessary restriction on minor premises of user-defined recursors
...
see issue #492
2015-05-18 10:09:11 -07:00
Leonardo de Moura
830d0ce1a7
fix(library/user_recursors): make sure homotopy.rec_on is recognized as a valid user-defined recursor
...
see issue #492
2015-05-18 09:57:50 -07:00
Leonardo de Moura
d4da381e1a
feat(tests/lean/run/tut_104): add extra test
2015-05-14 18:34:48 -07:00
Leonardo de Moura
84faef5d5d
feat(library/tactic/rewrite_tactic): rewrite tactic with 'iff' lemmas
2015-05-14 18:27:13 -07:00
Leonardo de Moura
7f8afcf04b
fix(frontends/lean/builtin_exprs): bug in 'using' expressions
2015-05-14 17:17:48 -07:00
Sebastian Ullrich
77c20e99ff
feat(library/tactic/inversion_tactic): consistent orientation of generated equalities
...
Generated equalities in proof irrelevant environments were inverted
compared with the documentation and the proof relevant case, which
resulted in newly generated local vars replacing equivalent old ones
instead of the other way around.
2015-05-14 23:32:54 +02:00
Leonardo de Moura
ea7694ca32
fix(tests/lean/slow/path_groupoids): to reflect changes in the libraries
2015-05-13 22:32:07 -07:00
Leonardo de Moura
cbcaf5a48e
fix(frontends/lean/scanner): block comments
...
fixes #600
2015-05-13 22:14:28 -07:00
Leonardo de Moura
163577c23a
fix(library/normalize): fixes #599
2015-05-13 18:36:16 -07:00
Leonardo de Moura
e0b39079eb
test(tests/lean/extra): add test for issue #597
2015-05-13 15:34:34 -07:00
Leonardo de Moura
11fbee269b
fix(frontends/lean/parser): must save state of name_generator in parser snapshot
...
To provide typing and auto-completion information, we create a
background process by starting lean with the option --server.
In "server" mode, we create snapshots of the parser state.
The idea is to be able to quickly reprocess a file when the user makes a
modification. This commit fixes a bug in the snapshot operation.
It was not saving in the snapshots the unique name generator used by the parser.
By creating a fresh name generator, we may accidentally
assign the same internal name to two different constants.
This bug triggered the crash described in issue #593 .
This commit fixes the test in the comment
https://github.com/leanprover/lean/issues/593#issuecomment-101768484
This commit also adds a smaller version of the problem to the test suite
2015-05-13 12:28:23 -07:00
Leonardo de Moura
f403ea984b
feat(frontends/lean): add 'print [recursor]' command for debugging purposes
2015-05-12 15:48:24 -07:00
Leonardo de Moura
750f6d5a43
feat(library,frontends/lean): validate user defined recursors and add attribute to mark them
...
see issue #492
The user-defined recursors will also be used to implement the blast tactic
2015-05-12 15:48:01 -07:00
Leonardo de Moura
3d8586088b
fix(frontends/lean/elaborator): problem with 'calc' proofs discussed at issue #592
2015-05-11 13:22:39 -07:00
Leonardo de Moura
d636b34c1c
fix(tests/lean): make sure tests do not fail when compiling Lean with cmake option "-DIGNORE_SORRY=ON"
2015-05-11 11:49:23 -07:00
Leonardo de Moura
c5fb3ec6d0
fix(library/definitional/equations): fixes #541
...
This commit allows recursive applications to have less or more arguments
than the equation left-hand-side.
We add two tests
- 541a.lean recursive call with more arguments
- 542b.lean recursive call with less arguments
2015-05-10 20:37:44 -07:00
Leonardo de Moura
8f711873a0
fix(tests/lean): adjust tests to reflect changes in the pretty printer
2015-05-10 11:10:38 -07:00
Leonardo de Moura
9812cfe906
test(tests/lean/run): add example for constructive choice
2015-05-09 12:02:52 -07:00
Leonardo de Moura
e9c8de7bdf
feat(frontends/lean): remove unnecessary option
2015-05-09 11:49:55 -07:00
Leonardo de Moura
d217655a62
fix(kernel/quotient/quotient): bug in reduction rule for quot.ind
2015-05-09 09:07:03 -07:00
Leonardo de Moura
4e35afedcc
feat(frontends/lean): rename 'wait' to 'reveal'
...
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2015-05-08 20:54:16 -07:00
Leonardo de Moura
f8e2f68ce0
feat(frontends/lean): add 'wait' command
...
This commit also fixes several problems with -j option (parallel
compilation). The .olean files were not missing data when -j was used
see issue #576
2015-05-08 20:05:21 -07:00
Leonardo de Moura
cf7e60e5a6
refactor(kernel): remove "opaque" field from kernel declarations
...
see issue #576
2015-05-08 16:06:16 -07:00
Leonardo de Moura
57ea660963
refactor(*): start process for eliminating of opaque
definitions from the kernel
...
see issue #576
2015-05-08 16:06:04 -07:00
Leonardo de Moura
061e26157e
fix(kernel,library): make sure macros check relevant arguments when kernel is performing full type checking
2015-05-08 12:41:23 -07:00
Leonardo de Moura
72663e8a06
feat(library/tactic/rewrite_tactic): take hypotheses into account when checking rewrite step
2015-05-08 11:34:50 -07:00
Leonardo de Moura
746e6dc0ff
fix(tests/lean): adjust tests output to reflect recent changes in the pretty printer
2015-05-08 11:11:00 -07:00
Floris van Doorn
ae43b244ef
fix(tests): fix tests to reflect recent changes
2015-05-07 16:39:04 -07:00
Leonardo de Moura
eb3a236119
fix(library/unifier): typo
...
fixes #588
2015-05-07 16:30:02 -07:00
Leonardo de Moura
f6a1d1c864
fix(frontends/lean/parser): fixes #584
2015-05-07 14:24:30 -07:00
Leonardo de Moura
aff9257c72
feat(frontends/lean): allow → to be used in calc proofs
...
see issue #586
2015-05-07 12:28:47 -07:00
Leonardo de Moura
b03266be70
feat(library/normalize,frontends/lean): rename '[unfold-m]' hint to '[constructor]', and allow it to be attached to constants
...
closes #587
2015-05-07 12:00:34 -07:00
Leonardo de Moura
5113f6b9d8
fix(tests/lean): test output to reflect recent changes
2015-05-07 10:01:28 -07:00
Leonardo de Moura
ac24f19210
fix(library/tactic/rewrite_tactic): use relaxed type checker when processing rewrite "proof step"
...
That is, the restricted type checker should only be used in the
matching/unification step.
fixes #583
2015-05-07 09:57:23 -07:00
Leonardo de Moura
5798ac43de
fix(frontends/lean/structure_cmd): 'structure' command must set unfold-c attribute for auxiliary recursors
...
fixes #582
2015-05-07 09:09:07 -07:00
Leonardo de Moura
171530d5cc
fix(frontends/lean/notation_cmd): fixes #585
2015-05-07 08:36:37 -07:00
Leonardo de Moura
16b7bc3922
fix(kernel/default_converter): broken optimization
...
we must also check the universe levels when applying the optimization for
constraints of the form:
f.{l_1 ... l_k} a_1 ... a_n =?= f.{l_1' ... l_k'} b_1 ... b_n
The optimization tries to avoid unfolding f if we can establish that
a_i is definitionally equal to b_i for each i in [1, n]
closes #581
2015-05-06 18:32:41 -07:00
Leonardo de Moura
02662fe489
test(tests/lean/run/new_obtain4): test new 'obtain' expression using minimal amount of annotations
2015-05-06 12:51:06 -07:00
Leonardo de Moura
613281d622
fix(frontends/lean/builtin_exprs): bug in new 'obtain' expression
2015-05-06 10:01:24 -07:00
Leonardo de Moura
26c662accd
feat(frontends/lean/builtin_exprs): improve new 'obtain' expression
2015-05-06 09:56:57 -07:00
Leonardo de Moura
84deddcca9
feat(library/tactic/rewrite_tactic): apply 'reflexivity' tactic after 'rewrite' instead of hard coded solution
2015-05-05 20:23:49 -07:00
Leonardo de Moura
c7a20644c0
fix(library/tactic/rewrite_tactic): bug in rewrite tactic (HoTT mode)
...
closes #580
2015-05-05 19:25:15 -07:00
Leonardo de Moura
a4efefb6ff
feat(library/tactic/rewrite_tactic): display type error message when
...
rewrite tactic fails
2015-05-05 19:23:41 -07:00
Leonardo de Moura
9bb8c5c98a
test(tests/lean/hott): test 'obtain' in the HoTT library
2015-05-05 18:57:09 -07:00
Leonardo de Moura
7cd444882c
feat(frontends/lean): add 'begin+' and 'by+' that enter tactic mode with the whole context visible
2015-05-05 18:47:25 -07:00
Leonardo de Moura
5d515a06f7
test(tests/lean/run): add test showing that "proof ... qed" can access the whole context
2015-05-05 18:32:47 -07:00
Leonardo de Moura
616f49c2e4
feat(frontends/lean): improved 'obtains' expression
2015-05-05 18:30:16 -07:00
Leonardo de Moura
741fca1e7b
feat(hott/init/path): mark 'idp' and 'idpath' with '[unfold-m]' hint
...
closes #496
2015-05-04 14:29:22 -07:00
Leonardo de Moura
6571c47353
feat(library/normalize): add '[unfold-m]' hint
...
See issue #496
2015-05-04 14:23:04 -07:00
Leonardo de Moura
b347f4868b
test(tests/lean/eq_class_error): save "workaround" for cryptic error message
2015-05-03 21:08:09 -07:00
Leonardo de Moura
87aaf373f4
fix(frontends/lean): fix '#' override notation on the left-hand-side of recursive equations (and match-expressions)
2015-05-03 21:08:09 -07:00
Leonardo de Moura
326048df54
feat(library/tactic/inversion_tactic): clear variables that have been eliminated by cases tactic
...
see discussion at:
https://groups.google.com/forum/#!topic/lean-discuss/oyzgIqdMyNc
2015-05-02 19:33:59 -07:00
Leonardo de Moura
441f1f9fe2
feat(frontends/lean): import error message for "unknown" tactics when parsing
2015-05-02 18:57:58 -07:00
Leonardo de Moura
118189eaac
fix(frontends/lean/elaborator): bug in translation function
...
This commit fixes the bug reported in the lean discussion list:
https://groups.google.com/forum/#!topic/lean-discuss/oyzgIqdMyNc
2015-05-02 18:05:07 -07:00
Leonardo de Moura
e1dc18f6b6
fix(library/tactic/inversion_tactic): check whether eliminator can only eliminate to Prop
...
fixes #571
2015-05-02 17:48:08 -07:00
Leonardo de Moura
e379034b95
feat(library/tactic): improve 'assumption' tactic
...
- It uses the unifier in "conservative" mode
- It only affects the current goal
closes #570
2015-05-02 17:33:54 -07:00
Leonardo de Moura
8c107d6936
fix(frontends/lean/builtin_cmds): bug in export
command
...
Cause: we have two different tokes to represent declarations: [decls] and [declarations]
fixes #568
2015-05-02 16:01:25 -07:00
Leonardo de Moura
b39fe17dee
feat(library/tactic): add 'transitiviy', 'reflexivity' and 'symmetry' tactics
...
closes #500
2015-05-02 15:48:25 -07:00
Leonardo de Moura
cd17618f4a
refactor(library): replace 'calc_trans', 'calc_symm', 'calc_refl' and 'calc_subst' commands with attributes '[symm]', '[refl]', '[trans]' and '[subst]'
...
These attributes are used by the calc command.
They will also be used by tactics such as 'reflexivity', 'symmetry' and
'transitivity'.
See issue #500
2015-05-02 15:15:35 -07:00
Leonardo de Moura
efc33a2f1d
fix(tests/lean): adjusts tests
2015-05-02 13:01:37 -07:00
Leonardo de Moura
415ca2b93f
feat(library/tactic): add 'congruence' tactic
...
It is the f_equal described at issue #500 .
2015-05-02 12:58:46 -07:00
Leonardo de Moura
230b994e79
fix(tests/lean/slow): adjust tests
2015-05-01 19:47:55 -07:00
Leonardo de Moura
9dc0388022
fix(library/tactic/rewrite_tactic): bug when rewriting hypotheses
2015-05-01 19:45:23 -07:00
Leonardo de Moura
ac8ba6a3cf
feat(library/tactic): add 'subst' tactic
...
see issue #500
2015-05-01 19:31:24 -07:00
Leonardo de Moura
b0759f3986
fix(library/tactic/rewrite_tactic): bug when rewriting multiple hypotheses
2015-05-01 19:03:43 -07:00
Leonardo de Moura
ea87dd48e3
chore(tests/lean/hott/inj_tac): fix typo
2015-05-01 18:18:57 -07:00
Leonardo de Moura
de369a0a0a
feat(library/tactic/injection_tactic): improve 'injection' tactic
...
see issue #500
2015-05-01 15:49:56 -07:00
Leonardo de Moura
9ba8b284a1
fix(library/tactic/apply_tactic): add eapply, and fix issue #361
2015-05-01 15:08:00 -07:00
Leonardo de Moura
63eb155c7e
feat(library/tactic): add 'injection' tactic
...
see issue #500
2015-05-01 12:45:21 -07:00
Leonardo de Moura
7e9f574ef3
fix(library/tactic/apply_tactic): use internally 'apply' instead of 'fapply' as the default "apply" tactic
...
This changes improves the 'constructor' tactic
2015-04-30 21:58:35 -07:00
Leonardo de Moura
4f7f66de3f
test(tests/lean/run): add new test
2015-04-30 21:38:33 -07:00
Leonardo de Moura
2d9c950144
feat(library/tactic/constructor_tactic): allow 'constructor' tactic without index
...
see issue #500
2015-04-30 21:15:07 -07:00
Leonardo de Moura
15e52b06df
fix(library/tactic/constructor_tactic): bug in constructor tactic
...
see example (constr_tac2.lean) in comment at issue #500
2015-04-30 20:18:24 -07:00
Leonardo de Moura
d18f9c7607
fix(library/tactic/constructor_tactic): use 1 (instead of 0) to reference the first constructor
...
see comment at issue #500
2015-04-30 20:08:00 -07:00
Leonardo de Moura
0b995c4fe3
fix(library/tactic/rewrite_tactic): relax reducibility constraints in some parts of the rewrite tactic
...
fixes #567
2015-04-30 18:22:58 -07:00
Leonardo de Moura
d152f38518
feat(library/tactic): add 'constructor', 'split', 'left', 'right' and 'existsi' tactics
...
see issue #500
2015-04-30 17:52:29 -07:00
Leonardo de Moura
125ab8c228
fix(tests/lean/interactive/findp): adjust test output
2015-04-30 15:45:15 -07:00
Leonardo de Moura
1c6067bac2
feat(library/tactic): add 'exfalso' tactic
...
see issue #500
2015-04-30 15:43:07 -07:00
Leonardo de Moura
9c8a63caec
feat(library/tactic): add 'contradiction' tactic
...
see issue #500
Remark: this tactic also applies no_confusion to take care of a contradiction
2015-04-30 13:47:40 -07:00
Leonardo de Moura
3233008039
feat(library/tactic): allow user to name generalized term in the 'generalize' tactic
...
closes #421
2015-04-30 11:57:40 -07:00
Leonardo de Moura
3912bc24c8
feat(frontends/lean): nicer syntax for 'intros' 'reverts' and 'clears'
2015-04-30 11:00:39 -07:00
Leonardo de Moura
d6d30f12c6
feat(frontends/lean): add "polymorphic" print command
...
closes #524
2015-04-29 16:17:33 -07:00
Leonardo de Moura
1a28a3c36f
feat(frontends/lean): add 'print inductive' command
2015-04-29 15:22:10 -07:00
Leonardo de Moura
dce7177382
feat(library/tactic/change_tactic): improve 'change' tactic
...
- Better error messages
- Try to solve unification constraints produced during is_def_eq test
addresses comment on issue #531
2015-04-29 13:31:09 -07:00
Leonardo de Moura
d055947243
feat(library/tactic/rewrite_tactic): ignore implicit argument when matching at rewrite tactic
2015-04-29 12:51:33 -07:00
Leonardo de Moura
b790ca9806
fix(library/tactic/rewrite_tactic): type check rewriting steps
...
closes #550
2015-04-29 12:16:37 -07:00
Leonardo de Moura
d1cb0018c0
fix(tests): adjust tests to reflect changes in the HoTT library
2015-04-29 10:15:13 -07:00
Leonardo de Moura
051615712c
fix(kernel/quotient/quotient): bug in reduction rule
2015-04-29 10:01:17 -07:00
Leonardo de Moura
d2c7b5c319
feat(library/tactic): add 'let' tactic
...
closes #555
2015-04-28 17:24:43 -07:00
Leonardo de Moura
1be72f1faa
feat(frontends/lean): parse argument of unary tactis with rbp=0, tokens may have a different precedence in expression and tactic modes
2015-04-28 13:43:05 -07:00
Leonardo de Moura
a23118d357
feat(frontends/lean): add tactic_notation command
...
This addresses the first part of issue #461
We still need support for tactic definitions
2015-04-27 17:46:13 -07:00
Leonardo de Moura
ca8943f45b
feat(library,hott): remove rapply tactic
2015-04-27 15:06:16 -07:00
Leonardo de Moura
9d01868361
feat(frontends/lean): use rewrite tactic to implement unfold (it has a unfold step)
...
closes #502
2015-04-24 17:23:12 -07:00
Leonardo de Moura
28404fe16d
fix(library/tactic/rewrite_tactic): second problem reported at issue #548
...
closes #548
2015-04-24 16:49:32 -07:00
Leonardo de Moura
6134c8822a
fix(frontends/lean/util): assertion violation
...
fixes #559
2015-04-24 15:09:23 -07:00
Leonardo de Moura
f723550d33
feat(frontends/lean/elaborator): decorates error message with free variables introduced by the left-hand-side of the equation
...
closes #528
2015-04-24 14:58:15 -07:00
Leonardo de Moura
8241863abe
feat(kernel/hits): add two builtin HITs: type_quotient and trunc
2015-04-23 15:32:31 -07:00
Leonardo de Moura
2613e7c444
fix(frontends/lean): bug when handling identifiers in tactics
...
This bug was reported by Jeremy in the Lean Google group:
https://groups.google.com/forum/?utm_medium=email&utm_source=footer#!msg/lean-discuss/ZKJ8WPPEVJA/n05x6rPRzvMJ
2015-04-22 16:03:22 -07:00
Leonardo de Moura
e1a609cad9
fix(tests/lean/interactive/findp): test output to reflect changes in the stdlib
2015-04-22 13:08:56 -07:00
Leonardo de Moura
349cdb3fe7
test(tests/lean): add test showing that the binder type update should not change the parameter order
2015-04-22 13:04:05 -07:00
Leonardo de Moura
a526cd92ac
fix(frontends/lean): bug in pretty printer
...
this is related to issue #530
2015-04-22 12:44:08 -07:00
Leonardo de Moura
dc93603b4a
feat(frontends/lean): parameter and variable binder type update
...
see issue #532
2015-04-22 12:28:11 -07:00
Leonardo de Moura
91f21c007a
feat(frontends/lean): remove 'context' command
2015-04-22 11:32:02 -07:00
Leonardo de Moura
53653c3526
fix(frontends/lean): pretty printing in sections with parameters
...
fix #530
2015-04-21 22:44:09 -07:00
Leonardo de Moura
8e9997e253
chore(tests/lean/interactive/sec_info_bug): remove 'context' command from test
2015-04-21 19:52:01 -07:00
Leonardo de Moura
fe9f4dd95f
fix(frontends/lean): another bug in sections with parameters
2015-04-21 19:50:21 -07:00
Leonardo de Moura
3df99e514b
fix(frontends/lean): problems with sections
2015-04-21 19:46:57 -07:00
Leonardo de Moura
9fb7aa9f1c
chore(tests): remove most occurrences of 'context' command from the test suite
2015-04-21 19:33:21 -07:00
Leonardo de Moura
ce153d01f9
test(tests/lean/sec_notation2): notation nested in namespace/section/section
2015-04-21 19:07:52 -07:00
Leonardo de Moura
52e9ad1a98
feat(frontends/lean): allow persistent notation declaration in sections (when they do not contain parameters)
...
see issue #554
2015-04-21 19:04:06 -07:00
Leonardo de Moura
bf8a7eb9b4
fix(library/scoped_ext): bug in local metadata in sections
...
The problem is described in issue #554
2015-04-21 18:56:28 -07:00
Leonardo de Moura
697a536d9e
fix(library/tactic/inversion_tactic): type incorrect term being built by 'cases' tactic
...
fixes #545
2015-04-20 19:24:52 -07:00
Leonardo de Moura
107763a506
fix(frontends/lean): better error message for 'proof ... qed' blocks containing unsolved placeholders
2015-04-20 15:50:37 -07:00
Leonardo de Moura
6f6d106a10
feat(library/tactic): add "check_expr" tactic
...
closes #486
2015-04-19 19:00:05 -07:00
Leonardo de Moura
60e320fd79
feat(frontends/lean): protected constants and axioms
...
fixes #527
2015-04-19 17:45:58 -07:00
Leonardo de Moura
b7ca2a0ec9
fix(library/tactic/exact_tactic): exact and or_else
...
fixes #543
2015-04-19 17:23:09 -07:00
Leonardo de Moura
306087b5d3
refactor(library/data): rename 'countable' to 'encodable', define countable in the usual way, and prove all 'encodable' type is 'countable'
2015-04-19 14:20:47 -07:00
Leonardo de Moura
cc63a40a01
feat(library): enforce name conventions on old nat declarations
2015-04-18 10:50:30 -07:00
Leonardo de Moura
3e5796acb2
fix(tests/lean/abbrev1): to reflect recent changes
2015-04-18 10:40:46 -07:00
Leonardo de Moura
f16eaf8f0f
test(tests/lean/run/pickle1): add unpickle/pickle test
2015-04-14 21:32:07 -07:00
Leonardo de Moura
795acc70a6
refactor(library/data/finset): move finset to its own directory
2015-04-09 19:30:09 -07:00
Leonardo de Moura
4416d9b2c5
test(tests/lean/run): add basic tests for finset module
2015-04-09 15:56:41 -07:00
Leonardo de Moura
24f1454c0a
fix(tests/lean/interactive/findp): adjust test output to reflect recent changes in the pretty printer
2015-04-08 09:49:22 -07:00
Leonardo de Moura
5d95cb0979
feat(library/tactic): add 'refine' tactic
...
closes #482
2015-04-06 18:36:56 -07:00
Leonardo de Moura
412f03b08b
feat(library/tactic/exact_tactic): generate error if 'exact' tactic produces a term containing metavariables
2015-04-06 13:38:53 -07:00
Leonardo de Moura
754276a660
feat(frontends/lean): round parenthesis for [tactic1 | tactic2]
...
This commit also replaces the notation for divides
`(` a `|` b `)`
with
a `∣` b
The character `∣` is entered by typing \|
closes #516
2015-04-06 09:24:09 -07:00
Leonardo de Moura
969d17fd12
fix(frontends/lean/elaborator): class inference in tactic mode with trunc
...
closes #477
2015-04-05 17:47:14 -07:00
Leonardo de Moura
bebe8a4f17
fix(tests/lean/bad_coercions): expected output
2015-04-05 03:00:29 -07:00
Leonardo de Moura
d731a4ab13
feat(library/normalize): add '[unfold-f]' hint
...
closes #497
2015-04-05 03:00:13 -07:00
Leonardo de Moura
d591c63840
feat(frontends/lean/decl_cmds): allow local coercions in contexts
...
closes #525
2015-04-04 15:25:07 -07:00
Leonardo de Moura
8c59f17605
feat(frontends/lean): 'using' expression without 'show' or 'have'
...
closes #536
2015-04-04 15:25:07 -07:00
Leonardo de Moura
4ec0e1b07c
feat(frontends/lean): improve calc mode
...
Now, it automatically supports transitivity of the form
(R a b) -> (b = c) -> R a c
(a = b) -> (R b c) -> R a c
closes #507
2015-04-04 08:58:35 -07:00
Leonardo de Moura
1150b19598
perf(frontends/lean/elaborator): do not invoke recursive equation compiler when equations still contain metavariables
2015-04-02 23:37:33 -07:00
Leonardo de Moura
f8023403af
test(tests/lean/run): add another simple test
2015-04-01 15:49:01 -07:00
Leonardo de Moura
bf142f3f18
fix(tests/lean): adjust tests to reflect changes in the standard library
2015-04-01 15:09:00 -07:00
Leonardo de Moura
0d66d19ba3
feat(tests/lean/run/finset): show that if A has decidable equality, then (finset A) also has it.
2015-04-01 13:19:16 -07:00
Leonardo de Moura
b960e123b1
feat(kernel): add experimental support for quotient types
2015-03-31 22:04:16 -07:00
Leonardo de Moura
82833bcbe8
fix(tests/lean/struct_class): add setoid to expected output
2015-03-31 22:03:57 -07:00
Leonardo de Moura
8c76419c60
fix(frontends/lean/decl_cmds): error localization problem for recursive equations
2015-03-30 13:30:29 -07:00
Leonardo de Moura
ec1a60b02c
feat(library/init/logic): add helper function for proving decidable equality
2015-03-30 02:14:26 -07:00
Soonho Kong
8243ed6339
fix(test*.sh): allow spaces in filename
...
fix #515
2015-03-28 23:29:52 -04:00