Leonardo de Moura
3d65b1c25c
fix(frontends/lean/elaborator): incorrect type information being reports in lean-mode, fixes #241
2014-10-10 15:41:55 -07:00
Leonardo de Moura
d61e6fdd89
refactor(frontends/lean/util): add auxiliary function
2014-10-10 15:21:08 -07:00
Leonardo de Moura
f7bbe09db2
feat(frontends/lean): add helper function mk_section_local_ref
2014-10-08 22:23:20 -07:00
Leonardo de Moura
bf01cfeec5
fix(frontends/lean): avoid superfluous local references of the form @-1 (@ f)
,
...
This kind of term also confuses the elaborator
2014-10-04 07:55:32 -07:00
Leonardo de Moura
e71d4548de
fix(frontends/lean): universe levels associated with section variables should not be fixed in the section
2014-10-04 07:13:19 -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
d5cad765a0
feat(frontends/lean): enforce new semantics for section 'variables'
...
The library file logic/core/connectives uses the new feature.
2014-10-02 17:55:34 -07:00
Leonardo de Moura
bf081ed431
refactor(kernel): rename var_decl to constant_assumption
...
Motivation: it matches the notation used to declare it.
2014-10-02 17:55:34 -07:00
Leonardo de Moura
263b081e69
fix(frontends/lean/inductive_cmd): temporary aliases must take explicit universes into account, fixes #215
2014-10-01 10:24:44 -07:00
Leonardo de Moura
21be308884
feat(frontends/lean/inductive_cmd): infer implicit argument annotation after elaboration, allow user to disable it by using '()' annotation, closes #210
2014-09-29 11:11:17 -07:00
Leonardo de Moura
29d6bff785
refactor(frontends/lean): explicit initialization/finalization
2014-09-23 10:00:36 -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
d0d23eb525
fix(frontends/lean/inductive_cmd): improve name resolution in inductive
...
command
The new test demonstrates the problem being fixed by this commit
2014-09-16 09:48:51 -07:00
Leonardo de Moura
570879b55f
feat(frontends/lean): add declaration to namespace without opening it, closes #161
2014-09-09 18:02:14 -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
5549295c47
fix(frontends/lean/inductive_cmd): bug when elaborating inductive tyoe parameters
...
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2014-09-06 11:38:32 -07:00
Leonardo de Moura
b5f595c432
fix(frontends/lean/inductive_cmd): bugs when declarating inductive datatypes in sections, fixes #141 , fixes #142
...
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2014-09-05 19:17:09 -07:00
Leonardo de Moura
364bba2129
feat(frontends/lean/inductive_cmd): prefix introduction rules with the name of the inductive datatype
...
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2014-09-04 17:26:36 -07:00
Leonardo de Moura
8743394627
refactor(kernel/inductive): replace recursor name, use '.rec' instead of '_rec'
...
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2014-09-04 15:04:57 -07:00
Leonardo de Moura
231039ad26
chore(frontends/lean/inductive_cmd): add auxiliary assertion for debugging
...
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2014-08-29 22:28:22 -07:00
Leonardo de Moura
2f699fa53a
feat(*): make sections 'permanent', and add 'transient' contexts, closes #88
...
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2014-08-23 15:45:15 -07:00
Leonardo de Moura
b13851ba13
feat(frontends/lean): add kind and type to index, closes #89
...
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2014-08-23 12:39:59 -07:00
Leonardo de Moura
a5f0593df1
feat(*): change inductive datatype syntax
...
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2014-08-22 15:46:10 -07:00
Leonardo de Moura
9588336c15
refactor(kernel/type_checker): remove "global" constraint buffer from type_checker, and use constraint_seq instead
...
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2014-08-20 16:46:19 -07:00
Leonardo de Moura
14d6b6d043
fix(frontends/lean/inductive_cmd): generate index for inductive decls, introduction rules, and recursor/eliminator
...
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2014-08-15 18:02:41 -07:00
Leonardo de Moura
4ad7e709aa
feat(frontends/lean): default for inductive types, closes #32
...
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2014-08-07 07:52:37 -07:00
Leonardo de Moura
33c77afc29
feat(frontends/lean/structure): add 'structure' command skeleton
...
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2014-07-28 19:59:38 -07:00
Leonardo de Moura
864fdd37da
refactor(library/aliases): aliases are from name to names
...
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2014-07-27 21:01:59 -07:00
Leonardo de Moura
faee08591f
fix(*): make sure elaborator and type_checker use the same "rules" for treating opaque definitions
...
This is a big change because we have to store in constraints whether we can use the "relaxed" rules or not.
The "relaxed" case says that when type checking the value of an opaque definition we can treat other opaque definitions in the same module as transparent.
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2014-07-27 12:12:54 -07:00
Leonardo de Moura
a450ad5a95
feat(frontends/lean/inductive_cmd): improve notation for declaring 'empty' inductive datatypes
...
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2014-07-25 11:24:01 -07:00
Leonardo de Moura
d69db172a1
chore(kernel/replace_fn): add syntax sugar for replace function
...
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2014-07-19 12:53:37 +01:00
Leonardo de Moura
2e6184a721
fix(frontends/lean): more bugs in section management
...
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2014-07-14 06:27:36 +01:00
Leonardo de Moura
b53e6eda58
refactor(frontends/lean): eliminate the abstract method 'family' from parser
...
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2014-07-14 05:44:06 +01:00
Leonardo de Moura
5c51be4585
refactor(frontends/lean): use expr_struct_set when collecting locals
...
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2014-07-14 04:12:58 +01:00
Leonardo de Moura
1a6d0784f2
feat(kernel/level): improve universe level normalization procedure
...
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2014-07-10 13:49:41 +01:00
Leonardo de Moura
c16951aba6
fix(library/aliases): aliasing behavior
...
The new test '../../tests/lean/run/alias3.lean' demonstrates the issue being fixed.
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2014-07-07 15:40:55 -07:00
Leonardo de Moura
e8bd267a00
fet(frontends/lean): allow coercions to sort-class in the types of variable and definitions
...
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2014-07-06 21:54:16 -07:00
Leonardo de Moura
9a13bef4f3
fix(frontends/lean): fix (and simplify) parameter universe inference
...
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2014-07-06 16:56:54 -07:00
Leonardo de Moura
c84218e24a
chore(frontends/lean/inductive_cmd): cleanup
...
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2014-06-30 17:16:10 -07:00
Leonardo de Moura
cb000eda13
refactor(kernel): store binder_infor in local constants
...
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2014-06-30 11:37:46 -07:00
Leonardo de Moura
193ce35419
refactor(frontends/lean/inductive_cmd): redesign inductive datatype elaboration, use the new elaborator, and use simpler algorithm to infer the resulting universe
...
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2014-06-28 15:33:56 -07:00
Leonardo de Moura
0adacb5191
feat(kernel): add infer implicit, and use it to infer implicit arguments of inductive datatype eliminators, and tag whether parameters should be implicit or not in introduction rules in the module inductive_cmd
...
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2014-06-28 13:57:36 -07:00
Leonardo de Moura
d055c4880f
feat(frontends/lean): connect new elaborator to frontend
...
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2014-06-25 08:31:00 -07:00
Leonardo de Moura
05d1832425
refactor(kernel/type_checker): improve ensure_pi and ensure_sort APIs
...
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2014-06-19 22:33:58 -07:00
Leonardo de Moura
bdab979e09
feat(frontends/lean): add inductive_cmd
...
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2014-06-18 16:00:59 -07:00