Commit graph

13 commits

Author SHA1 Message Date
Leonardo de Moura
bf0b675ca6 chore: fix tests 2022-06-01 06:36:25 -07:00
Sebastian Ullrich
8a02dfec4f feat: subsume variables under variable
/cc @leodemoura
2021-01-22 14:36:05 +01:00
Sebastian Ullrich
b2b78eb222 test: use printMessageEndPos for leantests 2021-01-15 16:27:59 +01: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
7c0216595e fix: remove duplicate error messages due to variable(s)
In Lean4, we re-elaborate `variable`(s) for each command, but we don't
want the error messages due to `variable` to appear in the log
multiple times.
2020-09-14 12:44:25 -07:00
Leonardo de Moura
21c8366645 chore: fix test output 2020-09-13 13:50:00 -07:00
Leonardo de Moura
e181c1adee refactor: add DefEqM
The idea is to make clear that the field `posponed` is transient
state. It is only used during `isDefEq`.
The refactoring was motivated by a bug I found where the `posponed`
constraints were not being handled correctly. For example,
the `check (e : Expr)` method was returning `true`, but leaving pending
universe constraints at `postponed`.

cc @Kha
2020-09-12 16:42:16 -07:00
Leonardo de Moura
a8de3c5115 fix: isDefEq configuration in the elaborator 2020-09-11 17:36:28 -07:00
Leonardo de Moura
565d617bab chore: fix test 2020-09-06 08:57:33 -07:00
Leonardo de Moura
d8855c2673 feat: elaborate all definitions using elabMutualDef 2020-09-06 07:23:47 -07:00
Leonardo de Moura
5e5b75af61 chore: remove withDeclId 2020-09-01 13:04:08 -07:00
Leonardo de Moura
6f1975aef5 feat: report errors for unassigned metavariables
We were not reporting unassigned metavariables due to
1- `_`
2- Named holes (e.g., `?x`)
3- Implicit arguments
2020-08-27 15:03:41 -07:00
Leonardo de Moura
b616e8d07a test: do issue
This is the example triggered a panic message in the new frontend when
we were encoding `do a; b` as `a *> b`.
See 7cdf917c9
2020-08-15 16:07:01 -07:00