Commit graph

4159 commits

Author SHA1 Message Date
Leonardo de Moura
790fd9c24b chore(library/match): remove unused procedure 2015-02-03 15:20:26 -08:00
Leonardo de Moura
f79f43c702 refactor(library/match): use "special" meta-variables instead of free variables to represent placholders in the higher-order matcher 2015-02-03 15:15:04 -08:00
Leonardo de Moura
fc6d9878c9 refactor(kernel): add expr_cache
It is the old instantiate_metavars_cache.
2015-02-03 14:59:55 -08:00
Jeremy Avigad
dc7b432482 feat(src/emacs/README.md): tell user that packages will be installed automatically. Closes #423. 2015-02-03 13:50:59 -08:00
Jeremy Avigad
875869fdbc fix(src/emacs/README.md): make minor grammatical corrections 2015-02-03 13:50:59 -08:00
Leonardo de Moura
45e62031e2 fix(library/match): bug in matcher 2015-02-03 13:46:19 -08:00
Leonardo de Moura
9d1e312c12 test(tests/lean/extra): add extra tests for 'print' command 2015-02-01 20:20:26 -08:00
Leonardo de Moura
7d9d89bae6 test(tests/lean/extra): add test for saving recursive equation pre-terms 2015-02-01 19:49:14 -08:00
Leonardo de Moura
15716c1471 feat(frontends/lean/calc_proof_elaborator): reject proofs with metavariables in the calc-assistant 2015-02-01 11:11:27 -08:00
Leonardo de Moura
4c7a17cc4a refactor(library/tactic/class_instance_synth): move has_expr_metavar_relaxed to util 2015-02-01 10:59:27 -08:00
Leonardo de Moura
c311e0aba6 chore(library/tactic/inversion_tactic): cleanup 2015-02-01 10:47:32 -08:00
Leonardo de Moura
143143e94c fix(library/tactic/inversion_tactic): missing normalization step in the inversion_tactic 2015-02-01 10:38:30 -08:00
Leonardo de Moura
d52af105d7 feat(frontends/lean/decl_cmds): allow many constants to be set in the same attribute command 2015-01-31 23:55:14 -08:00
Leonardo de Moura
855050e623 feat(frontends/lean/calc_proof_elaborator): try conservative alternatives first 2015-01-31 21:29:34 -08:00
Leonardo de Moura
27741e4fd7 chore(CMakeLists.txt): move Lean logo to make sure we can test leanemacs without installing Lean 2015-01-31 17:38:49 -08:00
Leonardo de Moura
099111db32 fix(CMakeLists.txt): option ==> set
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2015-01-30 14:49:20 -08:00
Leonardo de Moura
fbb543fdcf feat(CMakeLists.txt): add alternative image formats 2015-01-30 14:26:46 -08:00
Leonardo de Moura
6456c2b89a feat(CMakeLists.txt): add leanemacs.bat for Windows
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2015-01-30 14:16:57 -08:00
Soonho Kong
7bed63a03e doc(emacs/README.md): fix typos
[skip ci]
2015-01-30 16:10:21 -05:00
Leonardo de Moura
c8cb9aa3d2 fix(emacs/load-lean): typo 2015-01-30 13:05:30 -08:00
Leonardo de Moura
2c926478dd feat(bin): add leanemacs startup script 2015-01-30 13:05:30 -08:00
Leonardo de Moura
9910547913 feat(emacs): add script for loading lean mode and its dependencies 2015-01-30 13:05:30 -08:00
Leonardo de Moura
a57251913a feat(emacs): assume lua-mode and mmm-mode are available 2015-01-30 13:05:30 -08:00
Leonardo de Moura
d0ce4cf62f fix(CMakeLists.txt): path to ninja
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2015-01-30 10:37:49 -08:00
Leonardo de Moura
a44fec6eb4 fix(CMakeLists.txt): path to ninja
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2015-01-30 10:32:35 -08:00
Leonardo de Moura
1ee52a3ddc feat(CMakeLists.txt): include ninja in Windows binary distribution package
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2015-01-30 09:59:55 -08:00
Leonardo de Moura
7c59c959db fix(tests/lean/interactive): do not compare output of trace using non-deterministic commands such as "WAIT ms" 2015-01-30 09:52:42 -08:00
Soonho Kong
d98f04fd3a chore(emacs/README.md): add numbering on configuration
[skip ci]
2015-01-30 03:08:11 -05:00
Soonho Kong
04249a292c feat(emacs/README.md): add per-installation-method configurations 2015-01-30 03:05:35 -05:00
Soonho Kong
ce0aed12ec fix(emacs/Cask): add GNU package repository
Related issue #410
2015-01-30 02:52:55 -05:00
Soonho Kong
d69505a092 doc(emacs/README.md): add GNU package repository
flycheck uses let-alist package which is in GNU repository. @awody reported a problem and I hope that this can help (I'll test it later).

Reference: https://github.com/flycheck/flycheck/issues/551

Related issue: #410
2015-01-30 02:52:05 -05:00
Leonardo de Moura
f04e462bf3 test(tests/lean/interactive): add more tests for lean server 2015-01-29 16:30:07 -08:00
Leonardo de Moura
e9e1f86b7f fix(library/app_builder): many bugs, add use_cache option, add tests 2015-01-29 15:30:31 -08:00
Leonardo de Moura
e6f022e3f2 fix(library/match): index out of bounds 2015-01-29 14:41:38 -08:00
Leonardo de Moura
b5d1f4e54c feat(library/match): add low-level match API 2015-01-29 14:09:09 -08:00
Leonardo de Moura
f587cc3e1d feat(library/app_builder): expose app_builder API in Lua 2015-01-29 11:38:56 -08:00
Leonardo de Moura
5efd91e435 fix(library/app_builder): missing initialization 2015-01-29 11:38:28 -08:00
Leonardo de Moura
5bb2a41c64 feat(library/reducible): expose Lua API for reducible hints 2015-01-29 10:37:15 -08:00
Leonardo de Moura
4cf2dcaa7e feat(library/app_builder): add helper class for creating applications efficiently using type inference
The idea is to use this class in the simplifier.
For example, we will use to create: symmetry, reflexivity, transitivity
and congruence proof steps.
2015-01-28 18:40:21 -08:00
Leonardo de Moura
4e08cc0659 feat(library/match): add flag for tracking whether matcher assigned anything 2015-01-28 18:39:50 -08:00
Leonardo de Moura
dbc8e9e13a refactor(*): add method get_num_univ_params 2015-01-28 17:22:18 -08:00
Leonardo de Moura
5aaade47d8 feat(library/match): add new API 2015-01-28 16:42:42 -08:00
Leonardo de Moura
e4b5e07498 fix(frontends/lean/elaborator): apply substitution before compiling pre-tactics into tactics
closes #415
2015-01-28 13:32:56 -08:00
Leonardo de Moura
1119a8018a fix(util/buffer): destructor was not being invoked at erase and erase_elem
This bug was producing a weird memory leak in the definition package.
The methods erase and erase_elem are not used very often. This is why
this bug was never detected.
2015-01-27 18:48:02 -08:00
Leonardo de Moura
ad4c7c20f9 fix(kernel/inductive/inductive): fix assertion violation when K is applied to type incorrect term 2015-01-27 11:22:14 -08:00
Leonardo de Moura
1dbe4b8fb7 feat(kernel/extension_context): add auxiliary method is_def_eq 2015-01-27 11:17:54 -08:00
Leonardo de Moura
2a5658ebe2 fix(frontends/lean/elaborator_context): memory leak 2015-01-26 16:08:51 -08:00
Leonardo de Moura
e2c41fca75 feat(frontends/lean): modify syntax for local notation
The idea is to make it uniform with the syntax for defining local
attributes.
2015-01-26 11:51:17 -08:00
Leonardo de Moura
b4d6f6e3ed feat(frontends/lean): 'attribute' command is persistent by default 2015-01-26 11:51:17 -08:00
Leonardo de Moura
a1eeb0a6a1 fix(library/print): typo in is_used_name
closes #408
2015-01-25 08:58:08 -08:00
Leonardo de Moura
4f2e0c6d7f refactor(frontends/lean): add 'attribute' command
The new command provides a uniform way to set declaration attributes.
It replaces the commands: class, instance, coercion, multiple_instances,
reducible, irreducible
2015-01-24 20:23:21 -08:00
Leonardo de Moura
b5c4e603db feat(frontends/lean): allow parameters to be used in sections
Restriction:
- coercions and notations cannot be defined in parametric sections

closes #401
2015-01-23 17:42:19 -08:00
Leonardo de Moura
27f6bfd3f0 refactor(*): add file constants.txt with all constants used by the Lean binary 2015-01-23 16:50:32 -08:00
2d69444da5 fix(cmake/Modules/cpplint.py): python3 compatible without six 2015-01-22 13:05:56 -08:00
c1bfafd2a7 style(cmake/Modules/cpplint.py) 2015-01-22 13:05:56 -08:00
a2f30322a9 fix(cmake/Modules/cpplint.py): delete ending colon
Delete the erroneous ending colon.
2015-01-22 13:05:56 -08:00
51c771f334 revert(cmake/Modules/cpplint.py): roll back to python2 version
This reverts commit 65cc4d3c08.
2015-01-22 13:05:42 -08:00
Leonardo de Moura
880faf89e0 feat(frontends/lean/structure_cmd): add implicit_infer_kind annotation to structure command
closes #354
2015-01-21 18:12:29 -08:00
Leonardo de Moura
a53098385c refactor(frontends/lean/type_util): move infer_implicit_params to library 2015-01-21 17:22:41 -08:00
Soonho Kong
65cc4d3c08 fix(cmake/Modules/cpplint.py): roll back to python2 version 2015-01-21 19:26:38 -05:00
Leonardo de Moura
12674114a4 feat(shell): set default behavior to "trusted"
closes #402
2015-01-21 16:25:09 -08:00
073c1d1c31 feat(python): add python 3 compatibility
Add Python 3 compatibility through python-six library.

Closes #393.
2015-01-21 17:13:55 -05:00
Leonardo de Moura
1d6ff5f761 feat(library/definitional/projection): throw exception if unsupported case occurs
The user can workaround it by using trust-level 0 (i.e., no option -t num or -T)
2015-01-20 17:42:34 -08:00
Leonardo de Moura
01ce57e52e feat(library/definitional/projection): add projection macro 2015-01-20 16:21:50 -08:00
Leonardo de Moura
b6750e9d29 feat(library/util): add auxiliary functions 2015-01-20 15:44:58 -08:00
Leonardo de Moura
c51e2ac428 feat(kernel/type_checker): expose get_arity function 2015-01-20 14:25:07 -08:00
Leonardo de Moura
c43b2c8640 feat(kernel/extension_context): add auxiliary methods 2015-01-20 14:23:10 -08:00
Leonardo de Moura
8355ed55d7 refactor(library/definitional/projection): remove dead code 2015-01-20 13:40:09 -08:00
Leonardo de Moura
752b54085b refactor(kernel/type_checker): type checker should not unfold macros, but sign an error if a untrusted macro is used
Now, we unfold untrusted macros outside of the Lean kernel.
2015-01-20 12:36:56 -08:00
Leonardo de Moura
5ab7ff62b5 feat(CMakeLists): add --Trust option when building standard/hott libraries 2015-01-20 11:11:35 -08:00
Leonardo de Moura
260795f981 fix(frontends/lean/structure_cmd): collect universe levels that only occur in structure parameters
fixes #395
2015-01-19 22:18:09 -08:00
Leonardo de Moura
002050fa97 feat(frontends/lean): increase binding power of ! and @
Remark: I did not add the constant "app".
Reason: It would break the standard library in many places.
Moreover, the current "max" is not just the binding power of
application, but also the binding power of identifiers, (, [, ...
It would be weird to call it "app"

closes #388
2015-01-19 18:40:33 -08:00
Leonardo de Moura
dfbe6662be feat(frontends/lean/elaborator): add option 'elaborator.fail_if_missing_field' 2015-01-19 17:47:39 -08:00
Leonardo de Moura
2717adde94 feat(library/unifier): add option 'unifier.conservative', use option by default in the calc_assistant 2015-01-19 16:23:29 -08:00
Leonardo de Moura
d0e9e0e21c feat(library/definitional/projection): add auxiliary function for simplifying expressions containing projections and constructors 2015-01-18 20:58:40 -08:00
Leonardo de Moura
858d21f20b feat(library/definitional/projection): store projection information 2015-01-18 16:26:56 -08:00
Soonho Kong
901c9bf67a refactor: rename ltags => leantags
fix #394
2015-01-18 13:44:41 +09:00
Leonardo de Moura
edcc92d9c7 feat(frontends/lean): remove 'using' from structure instance command 2015-01-17 09:38:10 -08:00
Leonardo de Moura
f9d7480f5c feat(frontends/lean): notation for creating structure instances 2015-01-16 17:14:30 -08:00
Leonardo de Moura
bfd679d52d feat(frontends/lean/structure_cmd): allow user to reference parent structures when defining new fields
See new test for an example.

closes #371
2015-01-16 13:04:48 -08:00
Leonardo de Moura
13660cfecd feat(frontends/lean/parser): add parse_qualified_expr 2015-01-16 12:42:42 -08:00
Leonardo de Moura
6c07ca5d41 perf(library/print): improve is_used_name 2015-01-15 19:01:13 -08:00
Leonardo de Moura
c6290f01d0 perf(kernel/free_vars): improve has_free_var 2015-01-15 18:42:56 -08:00
Leonardo de Moura
f397da111a perf(kernel/error_msgs): avoid unnecessary work 2015-01-15 18:32:52 -08:00
Leonardo de Moura
ce0b1d17a2 perf(kernel/free_vars): improve has_free_var 2015-01-15 18:31:43 -08:00
Leonardo de Moura
ddcc8de09e fix(shell/lean): catch errors when loading bad cache file 2015-01-15 18:06:22 -08:00
Leonardo de Moura
30817aa2b1 feat(emacs): allow user to provide extra commands to lean-server 2015-01-15 16:54:55 -08:00
Leonardo de Moura
907f90096e feat(kernel): add memory consumption checks at replace_fn and for_each_fn 2015-01-15 16:54:55 -08:00
Leonardo de Moura
8ab775bd6f feat(*): distinguish between logical and runtime exceptions.
Now, we use throwable as the new base class for all Lean exceptions, and
exception is the subclass for "logical" exceptions.
2015-01-15 16:54:55 -08:00
Leonardo de Moura
3a865e95fe feat(shell/lean): add option '-M' to limit amount of memory consumed 2015-01-15 16:54:55 -08:00
Leonardo de Moura
5c9a277dea feat(CMakeLists): include runtime files in Windows binary distribution package
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2015-01-14 12:37:25 -08:00
Leonardo de Moura
730e038dd3 feat(CMakeLists): add basic example to binary distribution package 2015-01-14 10:39:07 -08:00
Leonardo de Moura
0509baa64a feat(CMakeLists): add README file for binary distribution packages 2015-01-14 10:35:51 -08:00
Leonardo de Moura
ee98523c2a feat(shell/lean): add option '-T' alias for '-t 1025' 2015-01-14 10:21:57 -08:00
Leonardo de Moura
3813aeede5 fix(util/lean_path): relative position of library files in binary
distribution packages
2015-01-14 10:14:17 -08:00
Leonardo de Moura
c9132648a2 feat(CMakeLists): include HoTT library in binary package 2015-01-14 10:00:35 -08:00
Leonardo de Moura
ef529c660f fix(library/definitional/no_confusion): mark no_confusion as reducible
Auxiliary definitions should be marked as reducible
2015-01-13 18:44:47 -08:00
Leonardo de Moura
e48df78938 feat(frontends/lean/elaborator): do not apply delayed_coercions on equation lhs
The variables in the equation lhs do not have type at preprocessing
time (i.e., their type is a metavariable). So, they may seem candidates
for delayed_coercions. If the coercions are injected, we will not be
able to pattern match. Thus, we disable coercions in this case.
2015-01-13 18:05:22 -08:00
Leonardo de Moura
37e852ba61 feat(frontends/lean/elaborator): improve error message for metavariable in inaccessible position on equation lhs 2015-01-13 14:38:25 -08:00
Leonardo de Moura
e9338669dc feat(library/definitional/equations): show implicit arguments (by default) in equations compiler error messages 2015-01-13 13:30:12 -08:00