Commit graph

19 commits

Author SHA1 Message Date
Kyle Miller
d31066646d
feat: make #check and #reduce typecheck terms (#5079)
These commands were trusting that elaboration resulted in type-correct
terms, but users testing custom elaborators have found it to be
surprising that they do not do typechecking. This adds a `Meta.check`
step.
2024-08-31 02:39:38 +00:00
Kim Morrison
3a457e6ad6
chore: use #guard_msgs in run tests (#4175)
Many of our tests in `tests/lean/run/` produce output from `#eval` (or
`#check`) statements, that is then ignored.

This PR tries to capture all the useful output using `#guard_msgs`. I've
only done a cursory check that the output is still sane --- there is a
chance that some "unchecked" tests have already accumulated regressions
and this just cements them!

In the other direction, I did identify two rotten tests:
* a minor one in `setStructInstNotation.lean`, where a comment says `Set
Nat`, but `#check` actually prints `?_`. Weird?
* `CompilerProbe.lean` is generating empty output, apparently indicating
that something is broken, but I don't know the signficance of this file.

In any case, I'll ask about these elsewhere.

(This started by noticing that a recent `grind` test file had an
untested `trace_state`, and then got carried away.)
2024-05-16 00:38:31 +00:00
Joe Hendrix
25147accc8
chore: upstream set notation (#3339)
This upstream Std Set notation except for [set
literals](1b4e6926f0/Std/Classes/SetNotation.lean (L115-L131)).
2024-02-15 02:08:45 +00:00
Leonardo de Moura
4657d47c16 chore: fix tests 2022-03-03 18:13:34 -08:00
Sebastian Ullrich
ee55ac5508 chore: fix test 2021-03-31 21:24:28 +02:00
Sebastian Ullrich
96c8cdfb14 chore: revert test changes 2021-03-25 10:35:22 +01:00
Leonardo de Moura
5ac7b1232a chore: add workarounds
@Kha It seems the recent parser modifications created some unexpected
problems. I didn't investigate them. I am "lost" in the elaborator and
dependent pattern matching land.

1) We can't write anymore
```
f [1, 2, 3] |>.run' 0 = Except.ok ()
```
We have to use parentheses and the error message is weird :(
```
(f [1, 2, 3] |>.run' 0) = Except.ok ()
```

2) I had to add comments to `macro.lean`, I didn't find a workaround
for one of the rules. BTW, I had to add a bunch of `:term` for fixing
the other rules, and the error messages were counterintuitive.
2021-03-23 18:35:27 -07:00
Leonardo de Moura
db9e390b4d chore: remove new_frontend from tests 2020-10-25 09:16:38 -07:00
Leonardo de Moura
f46dcd7a13 chore: fix some tests 2020-06-08 16:12:06 -07:00
Sebastian Ullrich
60ac03916e feat: introduce anonymous antiquotations for all categories 2020-05-26 14:32:42 +02:00
Leonardo de Moura
2b63aa27d3 chore: use new_frontend in the whole test 2020-01-21 09:16:38 -08:00
Leonardo de Moura
47c85cc351 fix: bug at ParserDescr.ident 2020-01-20 21:55:16 -08:00
Leonardo de Moura
98033f298f feat: add support for simple category 2020-01-20 20:55:54 -08:00
Leonardo de Moura
a98b6763ad fix: code and tests 2020-01-17 08:11:06 -08:00
Leonardo de Moura
d9c6624a0a feat: add support for trailing syntax 2020-01-15 20:53:23 -08:00
Leonardo de Moura
b9c161b30c feat: elaborate macro command 2020-01-15 20:53:23 -08:00
Leonardo de Moura
42de170088 chore: fix test 2020-01-15 20:53:23 -08:00
Leonardo de Moura
664172d266 feat: elaborate syntax command 2020-01-14 18:18:43 -08:00
Sebastian Ullrich
2e5f62d44f test: parser/macro macros 2020-01-12 10:32:27 -08:00