Leonardo de Moura
f0272d9309
feat: multiple namespaces in mutual declarations
2022-08-04 19:18:49 -07:00
Leonardo de Moura
e564ae834a
doc: add doc strings
2022-07-29 18:58:36 -07:00
Leonardo de Moura
92d360353c
feat: elaborate add_decl_doc
2022-07-27 09:58:49 -07:00
Leonardo de Moura
635752dd2c
feat: add info node from attributes to their parsers
...
see #1374
2022-07-27 06:12:43 -07:00
Mario Carneiro
f6211b1a74
chore: convert doc/mod comments from /- to /--//-! ( #1354 )
2022-07-22 12:05:31 -07:00
Gabriel Ebner
ff3c67d1ad
feat: recover from errors in attributes
2022-07-16 06:19:54 -07:00
Gabriel Ebner
eba400543d
refactor: use computed fields for Name
2022-07-11 14:19:41 -07:00
Leonardo de Moura
77ae79be46
chore: use let/if in do blocks
2022-06-13 17:10:14 -07:00
Leonardo de Moura
9ba5831de8
fix: _root_ prefix in declarations
...
closes #490
2022-06-13 14:03:18 -07:00
E.W.Ayers
917fa74366
doc: docstrings for decls and attributes
...
Co-authored-by: Sebastian Ullrich <sebasti@nullri.ch>
2022-04-08 04:19:38 -07:00
Leonardo de Moura
3862e7867b
refactor: make String.Pos opaque
...
TODO: this refactoring exposed bugs in `FuzzyMatching` and `Lake`
closes #410
2022-03-20 10:47:13 -07:00
Leonardo de Moura
d4d9995952
feat: reject user declared namespaces containing _root
...
see #490
2022-01-26 19:15:45 -08:00
Leonardo de Moura
7b6732a137
refactor: ExprDefEq.lean and LevelDefEq.lean are now implementation only files
...
We use the export/extern idiom to define `isLevelDefEqAux`, and then
define the `isDefEq` user facing functions at `Meta/Basic.lean`.
2021-12-06 09:57:00 -08:00
Leonardo de Moura
f46eedac84
fix: fixes #655
2021-09-07 12:17:28 -07:00
Leonardo de Moura
21c68a49e3
feat: elaborate nonrec modifier
2021-08-21 17:02:54 -07:00
Wojciech Nawrocki
f51b80060d
feat: generic tagged Format
2021-08-01 09:58:44 +02:00
Leonardo de Moura
d70f9c232c
feat: trace support for MacroM
...
closes #184
2021-04-23 19:15:14 -07:00
Leonardo de Moura
583afaab10
chore: indent syntax
2021-03-31 17:05:34 -07:00
Leonardo de Moura
be841a7cad
chore: throwError! => throwError, throwErrorAt! => throwErrorAt
...
@Kha I marked the corresponding methods as `protected`.
I currently can't stand `throw_error`, and I am optimistic about
server highlighting feature you are working on :)
2021-03-11 11:59:45 -08:00
Leonardo de Moura
164577d94e
chore: remove parser! and tparser!
...
The new macros are called "leading_parser` and `trailing_parser`.
cc @Kha
2021-03-11 09:36:58 -08:00
Sebastian Ullrich
0c91b3769e
chore: replace variables in src/
2021-01-22 14:36:05 +01:00
Leonardo de Moura
308c61027a
feat: save doc strings
...
We can now document `let rec` too.
2021-01-10 07:13:33 -08:00
Leonardo de Moura
195ec0705e
feat: expand macros in attributes eagerly
...
The `AttrM` monad does not have sufficient information for expanding
macros. So, we expand them eagerly before we invoke the attributer
handlers implemented using `AttrM`.
cc @Kha
2020-12-15 15:11:19 -08:00
Leonardo de Moura
4001407f10
refactor: add MonadError class abbreviation
2020-12-14 09:15:26 -08:00
Leonardo de Moura
3b6d65c3c3
chore: use deriving Inhabited
2020-12-13 10:09:20 -08:00
Leonardo de Moura
44d0fe993a
feat: ensure scoped instances cannot be used outside namespaces
2020-12-05 16:26:31 -08:00
Leonardo de Moura
9d304df757
feat: heterogeneous Append experiment
...
@Kha This one required a bunch of manual fixes. The main issue is that
before we added the string interpolation feature, we created
`MessageData`s using `++` and coercions. For example, given
`(e : Expr)`, we would write
```
let msg : MessageData := "type: " ++ e
```
and rely on the coercions `String -> MessageData` and
`Expr -> MessageData`, and the instance `Append MessageData`.
However, heterogeneous operators "block" the expected type propagation downwards.
This kind of code is obsolete now since we can write a more compact
version using string interpolation
```
let msg := m!"type: {e}"
```
2020-12-01 16:32:41 -08:00
Leonardo de Moura
0869f38de4
chore: update structure, class, inductive
2020-11-27 15:09:30 -08:00
Leonardo de Moura
c305c2691f
chore: use :=
2020-11-19 07:22:31 -08:00
Leonardo de Moura
396e767f3d
refactor: move Ref to Prelude and rename it to MonadRef
...
`MacroM` will implement `MonadRef` because
1- It will be easier to throw errors from macros
2- We will be able to `getRef` to retrieve the syntax node at macro
rules.
I renamed `Ref` to `MonadRef` to make it consistent with other classes
providing monadic methods (e.g. `MonadEnv`, `MonadState`, etc).
cc @Kha
2020-11-13 16:00:31 -08:00
Leonardo de Moura
f17e226638
chore: naming convention
...
Example: `mkNameStr` => `Name.mkStr`
cc @Kha
2020-11-11 10:08:55 -08:00
Leonardo de Moura
ff493751b5
chore: HasFormat ==> ToFormat
2020-10-27 16:19:14 -07:00
Leonardo de Moura
10c32fcf94
chore: HasToString => ToString
2020-10-27 16:11:48 -07:00
Leonardo de Moura
13c2a8ff51
chore: remove #lang lean4 header
2020-10-25 09:54:07 -07:00
Leonardo de Moura
82ee2e361b
chore: cleanup
2020-10-21 18:43:47 -07:00
Leonardo de Moura
43efdd50f7
chore: move to new frontend
2020-10-14 17:38:17 -07:00
Leonardo de Moura
6ac227a63c
chore: elabAttrs, elabDeclAttrs
2020-09-20 07:39:14 -07:00
Leonardo de Moura
a28679358e
refactor: remove MonadError
2020-09-18 09:58:13 -07:00
Leonardo de Moura
163b0a7a3f
fix: protected
...
- `protected` outside of a namespace is an error.
- Fix `protected` in recursive definitions.
cc @Kha
2020-09-14 13:09:04 -07:00
Leonardo de Moura
5ced8867b0
feat: anonymous instances and support for all kinds of definition at mutual
2020-09-01 17:00:00 -07:00
Leonardo de Moura
d74551b19e
feat: elaborate header of mutually recursive definitions
2020-09-01 16:13:04 -07:00
Leonardo de Moura
9f16d01058
refactor: reduce DeclModifiers dependencies
2020-08-31 10:12:06 -07:00
Leonardo de Moura
bb3c8a2105
refactor: polymorphic applyAttributes
2020-08-27 10:46:33 -07:00
Leonardo de Moura
de2df5955f
refactor: polymorphic checkNotAlreadyDeclared
2020-08-26 13:42:57 -07:00
Leonardo de Moura
8a9b031a9d
refactor: add Lean/Elab/Attributes.lean
2020-08-26 09:54:48 -07:00
Leonardo de Moura
a413da856f
refactor: polymorphic elabAttrs and elabAttr
2020-08-26 09:50:03 -07:00
Leonardo de Moura
05a0e7f6d0
refactor: build all main monads on top of ECoreM
2020-08-20 18:36:04 -07:00
Leonardo de Moura
68a4c145f7
refactor: implement attribute hooks using CoreM
...
We were using a mix of `IO` and `Except`
2020-08-19 14:44:54 -07:00
Leonardo de Moura
5ba9aad7a3
refactor: eliminate ref plumbing
2020-08-13 10:37:53 -07:00
Leonardo de Moura
0118de09b9
chore: add mkAuxDefinition
2020-07-24 10:45:32 -07:00