Leonardo de Moura
8ffadce4ab
feat(frontends/lean): add "premise" and "premises" command
...
It is just an alternative notation for "variable" and "variables"
closes #429
2015-02-11 18:46:03 -08:00
Leonardo de Moura
93f04f3034
feat(emacs): update syntax highlight
2015-02-11 10:35:38 -08:00
Leonardo de Moura
373d4ca4c6
feat(emacs/lean-syntax): highlight 'abbreviation' command
2015-02-10 18:22:03 -08:00
Leonardo de Moura
c04c0e8381
refactor(*): remove transparent_scope hack, replace [strict] with [all-transparent] annotation
2015-02-07 15:19:41 -08:00
Leonardo de Moura
5b25da8c43
feat(frontends/lean): add esimp tactic based on rewrite tactic
...
closes #358
2015-02-06 14:13:32 -08:00
Leonardo de Moura
979d6494e9
feat(emacs/lean-syntax): add syntax-highlight for unfold-c hint attribute
2015-02-06 12:57:11 -08:00
Leonardo de Moura
c845e44777
feat(frontends/lean): parse rewrite tactic
2015-02-04 11:51:39 -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
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
b172229a72
feat(frontends/lean): add 'match' expressions
...
We reuse the equations infrastructure to compile them.
2015-01-10 10:11:13 -08:00
Soonho Kong
f370871574
fix(emacs/lean-syntax): highlight axioms
...
fix #382
2014-12-30 14:25:19 -05:00
Leonardo de Moura
d2958044fd
feat(frontends/lean): add multiple_instances command
...
After this commit, Lean "cuts" the search after the first instance is
computed. To obtain the previous behavior, we must use the new command
multiple_instances <class-name>
closes #370
2014-12-21 17:28:44 -08:00
Leonardo de Moura
6f78315aa4
refactor(*): add uniform names for "meta-objects"
2014-12-17 11:42:14 -08:00
Leonardo de Moura
d09bc95eaf
feat(emacs): add Type0 highlight
2014-12-05 22:14:28 -08:00
Leonardo de Moura
e868ecce36
feat(frontends/lean): parse recursive equations
2014-12-04 17:03:21 -08:00
Leonardo de Moura
8dfd22e66c
feat(frontends/lean): add 'prelude' command, and init directory
2014-11-30 17:03:08 -08:00
Leonardo de Moura
c08f4672e4
feat(library/tactic): add 'assert' tactic, closes #349
2014-11-29 21:34:49 -08:00
Leonardo de Moura
f51fa93292
feat(library/tactic): add 'fapply' tactic, closes #356
2014-11-29 19:20:41 -08:00
Leonardo de Moura
ad0dfb4c64
fix(emacs): syntax highlight for 'cases ... with ...'
2014-11-28 22:41:46 -08:00
Leonardo de Moura
c2602baf2b
feat(library/tools/tactic): add 'cases' alias for 'inversion' tactic
2014-11-28 19:33:11 -08:00
Leonardo de Moura
f8fa9f3344
feat(emacs): highlight 'inversion' tactic
2014-11-27 10:26:32 -08:00
Leonardo de Moura
63eafaae9a
feat(emacs): add syntax-highlight for clear and revert tactics
2014-11-26 14:33:28 -08:00
Leonardo de Moura
f1e915a188
feat(frontends/lean): add 'find_decl' command
2014-11-23 23:00:59 -08:00
Leonardo de Moura
13fba433b0
feat(library/tactic/generalize): add 'generalizes' syntax sugar, closes #327
2014-11-23 17:30:22 -08:00
Leonardo de Moura
47b6cfb28d
feat(library/logic/if): add dependent if-then-else: dite
2014-11-22 09:56:32 -08:00
Leonardo de Moura
28c63e685b
feat(frontends/lean): add '[local]' notation, closes #322
2014-11-16 21:15:04 -08:00
Leonardo de Moura
50973bb4f3
feat(frontends/lean): default 'eval' command ignores opaque/irreducible annotations
...
To retrieve the previous behavior, we should use [strict] modifier
2014-11-10 12:46:04 -08:00
Leonardo de Moura
bd5f3ec572
feat(emacs/lean-syntax): highlight [decls] modifier
2014-11-10 10:35:42 -08:00
Leonardo de Moura
c7992f2cac
feat(frontends/lean): add [whnf] modifier to eval command
2014-11-08 10:19:29 -08:00
Soonho Kong
d861c78072
fix(emacs/lean-syntax): change comment symbols to be considered as punctuations
...
Please read the documentation of "modify-syntax-entry":
"The first character of NEWENTRY should be one of the following:
_ symbol constituent
. punctuation
"
Close : #306
2014-11-07 17:48:21 -05:00
Leonardo de Moura
85d0521d48
feat(frontends/lean): add '[parsing-only]' modifier to notation declarations, closes #305
2014-11-06 21:34:05 -08:00
Leonardo de Moura
ed83b7ff2a
fix(emacs/lean-syntax): syntax highlight, issue #306
...
1- FIXED structure foo := (bar : Type) -- the name of structures is not highlighted
2- NOT FIXED check foo-- this comment is not highlighted
3- FIXED check Type.{5} -- Type is not highlighted
4- FIXED definition bar{thisishighlighted : Type} := foo
5- FIXED definition bar2 {thetypeofthisvariableisnothighlighted :Type} := foo
Have no idea what is going on with 2. I'm not sure if this is our bug,
or Emacs code we depend on.
2014-11-06 20:59:31 -08:00
Leonardo de Moura
4650791108
feat(frontends/lean): add 'print fields' command
2014-11-05 14:06:54 -08:00
Leonardo de Moura
defc2478b5
feat(frontends/lean): add 'record' as an alias for 'structure' command
2014-11-05 12:02:52 -08:00
Leonardo de Moura
101e9966fd
fix(emacs/lean-syntax): bug in syntax highlight, examples do not have names
2014-11-03 18:32:18 -08:00
Leonardo de Moura
1e6f7cdbb4
chore(frontends/lean/decl_cmds): add 'example' command
...
It is like a theorem, but it is discarded after checking
2014-11-01 11:37:39 -07:00
Leonardo de Moura
591e566472
feat(frontends/lean): try to inject symmetry (if needed) in calc proofs, add calc_symm command for configuring the symmetry theorem for a given operator
...
This is part of #268
2014-10-30 23:24:09 -07:00
Leonardo de Moura
9547e2d077
feat(library/tactic): add rotate_left/rotate_right tactics, closes #278
2014-10-29 19:13:55 -07:00
Soonho Kong
17455d191b
feat(emacs/lean-mode): add lean-info-mode for "*lean-info*" buffer
2014-10-29 14:33:05 -07:00
Soonho Kong
12824c3e27
fix(emacs/lean-syntax): fix Type1, Type2 highlight
2014-10-29 14:33:05 -07:00
Leonardo de Moura
e22eb3543c
feat(library/tactic): add whnf tactic, closes #270
2014-10-28 23:18:49 -07:00
Leonardo de Moura
08e8161243
feat(emacs/lean-syntax): add 'eassumption' highlight
2014-10-26 15:45:26 -07:00
Leonardo de Moura
50948be66b
fix(emacs/lean-syntax): syntax highlight for composite names in declarations
2014-10-26 09:27:17 -07:00
Leonardo de Moura
79d0347721
feat(library/tactic): add generalize tactic, closes #34
...
Remark: the intros tactic has been added in a different commit: 7d0100a340
2014-10-23 22:40:15 -07:00
Leonardo de Moura
c50227ea6e
feat(library/tactic): change apply tactic semantics: goals are not reversed; and dependent arguments are not included
...
This commit also adds the tactic rapply that corresponds to the previous
semantics we have been using.
2014-10-22 18:11:09 -07:00
Leonardo de Moura
e95c7c5f70
refactor(library/tactic/rename_tactic): use new 'tactic.expr' to implement 'intro/intros' tactic
...
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2014-10-22 17:29:50 -07:00
Leonardo de Moura
bb953b80aa
feat(frontends/lean): reserve notation, closes #95
2014-10-21 15:39:47 -07:00
Leonardo de Moura
92acd9affc
chore(emacs): do not highlight arbitrary types
2014-10-20 19:17:02 -07:00
Leonardo de Moura
7d0100a340
feat(library/tactic): add 'intros' tactic
2014-10-20 15:26:16 -07:00
Leonardo de Moura
e6606ef2ac
feat(library/tactic): add 'rename' hypothesis tactic
2014-10-14 18:19:34 -07:00
Leonardo de Moura
ab90a350b3
fix(emacs/lean-syntax): syntax highlight for declarations with explicit universes
2014-10-13 06:52:36 -07:00
Leonardo de Moura
6a40f80612
fix(emacs/lean-syntax): glitch on syntax highlight
2014-10-11 10:56:28 -07:00
Leonardo de Moura
402a351937
feat(frontends/lean): add 'universes' command
2014-10-10 08:45:59 -07:00
Leonardo de Moura
d8572e249d
feat(frontends/lean/builtin_cmds): add 'print classes' command
2014-10-07 17:30:57 -07:00
Leonardo de Moura
16562adb87
feat(frontends/lean): add 'coercions' and 'instances' to 'print' command, closes #71
2014-10-05 18:50:48 -07:00
Leonardo de Moura
c0725d1934
refactor(frontends/lean): remove 'including' expressions
2014-10-03 09:09:27 -07:00
Leonardo de Moura
284f300440
feat(frontends/lean): add 'include' and 'omit' commands, closes #184
2014-10-03 07:23:24 -07:00
Leonardo de Moura
4946f55290
refactor(frontends/lean): constant/axiom are top-level commands, parameter/variable/hypothesis/conjecture are section/context-level commands
...
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2014-10-02 17:55:34 -07:00
Leonardo de Moura
9a75298892
feat(emacs): highlight Type'
2014-10-02 08:04:00 -07:00
Soonho Kong
89a929e9cd
feat(emacs/lean-syntax): add more word constituents to syntax table
2014-09-30 15:41:18 -07:00
Soonho Kong
106399179f
fix(emacs/lean-syntax): use word-boundary instead of symbol-boundary
2014-09-29 12:32:46 -07:00
Leonardo de Moura
397395bbc9
feat(frontends/lean): allow user to associate priorities to class-instances, closes #180
2014-09-28 12:20:42 -07:00
Leonardo de Moura
e430dc8bab
feat(frontends/lean): add 'irreducible' as syntax sugar for 'reducible [off]'
2014-09-19 15:54:32 -07:00
Leonardo de Moura
4e2377ddfc
refactor(frontends/lean): replace '[protected]' modifier with 'protected definition' and 'protected theorem', '[protected]' is not a hint.
...
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2014-09-19 15:54:32 -07:00
Leonardo de Moura
5d8c7fbdf1
refactor(frontends/lean): replace '[private]' modifier with 'private
...
definition' and 'private theorem', '[private]' is not a hint.
2014-09-19 15:54:32 -07:00
Leonardo de Moura
97b1998def
refactor(frontends/lean): replace '[opaque]' modifier with 'opaque
...
definition', '[opaque]' is not a hint, but a kind of definition
2014-09-19 15:54:32 -07:00
Leonardo de Moura
08ccd58eb6
feat(frontends/lean): add 'reducible' modifier for controlling which
...
definitions are unfolded during elaboration
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2014-09-19 15:54:32 -07:00
Leonardo de Moura
baf4c01de8
feat(frontends/lean): definitions are opaque by default
2014-09-19 15:54:32 -07:00
Leonardo de Moura
93c2c30310
feat(frontends/lean): allow transient coercions, i.e., coercions that
...
are not saved in .olean files
2014-09-19 15:54:32 -07:00
Leonardo de Moura
e3e2370a38
feat(frontends/lean): split 'opaque_hint' command into 'opaque' and 'transparent'
...
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2014-09-16 18:03:40 -07:00
Leonardo de Moura
010ecebfea
feat(frontends/lean): add proof-qed expression
...
Remark: we still have to add support to it in the elaborator.
Right now, it is just an embellished parenthesis.
2014-09-11 18:14:49 -07:00
Leonardo de Moura
b4793df653
feat(frontends/lean): rename '[fact]' to '[visible]'
...
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2014-09-08 07:47:42 -07:00
Leonardo de Moura
c378a58cc2
feat(frontends/lean): add [class] modifier for inductive datatypes as a shortcut for 'class' command.
2014-09-07 18:16:33 -07:00
Leonardo de Moura
d6491399b9
fix(emacs/lean-syntax): weird syntax-hightlight problem"
2014-09-06 10:49:16 -07:00
Leonardo de Moura
3bbbd43b03
chore(emacs): minor adjustments to synthax hightlight and input mode
...
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2014-09-06 08:32:05 -07:00
Leonardo de Moura
8610330cc4
chore(emacs/lean-syntax): highlight 'import/section/end/namespace/open' arguments
...
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2014-09-05 18:38:41 -07:00
Leonardo de Moura
b94ec07b29
feat(frontends/lean): associate type information with left '('
...
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2014-09-04 09:56:27 -07:00
Leonardo de Moura
f9a90b9920
feat(frontends/lean): add 'export' command
...
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2014-09-03 18:37:01 -07:00
Leonardo de Moura
5e18e6609c
feat(frontends/lean): add 'as' clause to 'open' command
...
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2014-09-03 17:37:02 -07:00
Leonardo de Moura
e51c4ad2e9
feat(frontends/lean): rename 'using' command to 'open'
...
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2014-09-03 16:00:38 -07:00
Leonardo de Moura
6a6f6ed439
feat(emacs/lean-syntax): add syntax-highlight for declaration modifiers
...
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2014-09-03 15:26:21 -07:00
Leonardo de Moura
5a203d1c75
feat(frontends/lean): add '?' for inspecting the type of any expression, it produces a EXTRA_TYPE info entry
...
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2014-09-03 11:54:42 -07:00
Soonho Kong
78437331c2
fix(emacs/lean-syntax.el): highlight "parameter (" properly
...
fix #122
2014-09-02 15:09:49 -07:00
Leonardo de Moura
0f9478d91e
feat(frontends/lean): add 'class' command back
...
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2014-09-02 15:04:23 -07:00
Leonardo de Moura
d9fa9f1039
feat(src/emacs/lean-syntax.el): add commonly used operators
...
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2014-08-28 13:03:22 -07:00
Leonardo de Moura
f98ab2a8ff
fix(src/emacs/lean-syntax.el): remove obsolete command set_opaque
...
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2014-08-28 11:16:29 -07:00
Leonardo de Moura
b3615d5c8b
fix(src/emacs): add 'begin' reserved keyword
...
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2014-08-28 09:33:09 -07:00
Soonho Kong
495809d86d
feat(emacs/lean-syntax): support multi-line comments /- ... -/
2014-08-26 16:22:30 -07:00
Soonho Kong
51b86b219b
feat(emacs/lean): add multi-line comments
...
This is related with issue #63 .
There are two known issues:
- Emacs behaves as if the multi-line comment start/end symols are "(-"
and "-)" instead of "(--" and "--)". As a result, it shows all the
correct lean comments as it is. However, it will show some examples
such as "(-5)" as a part of comment even if Lean doesn't interpret it
as it is. Technically, it's because we are using a syntax-table based
method to define comments. For more information read a documentation
of 'modify-syntax-entry' function.
- Somehow, the matching parens are broken. When we type "--)" to close
a multi-line comment. Emacs warns "Mismatched Parentheses".
2014-08-19 15:03:51 -07:00
Soonho Kong
46013b6ad2
feat(emacs): define lean-mode as a derived-mode of prog-mode
...
Fix #52
2014-08-18 13:32:58 -07:00