mirror of
https://github.com/leanprover/lean4.git
synced 2026-03-17 18:34:06 +00:00
This PR sets up the new integrated test/bench suite. It then migrates all benchmarks and some related tests to the new suite. There's also some documentation and some linting. For now, a lot of the old tests are left alone so this PR doesn't become even larger than it already is. Eventually, all tests should be migrated to the new suite though so there isn't a confusing mix of two systems.
24 lines
590 B
Lean4
24 lines
590 B
Lean4
import Lean open Lean
|
|
|
|
syntax "👉" (ident <|> "_") : term
|
|
#check fun x => `(👉 $x)
|
|
#eval match Unhygienic.run `(👉 _) with
|
|
| `(👉 $_:ident) => false
|
|
| `(👉 _) => true
|
|
| _ => false
|
|
#eval match Unhygienic.run `(👉 x) with
|
|
| `(👉 _) => false
|
|
| `(👉 $_:ident) => true
|
|
| _ => false
|
|
|
|
syntax "bar" (&"baz" <|> &"boing") : term
|
|
#check fun x => `(bar $x)
|
|
#eval match Unhygienic.run `(bar boing) with
|
|
| `(bar baz) => false
|
|
| `(bar boing) => true
|
|
| _ => false
|
|
#eval match Unhygienic.run `(bar baz) with
|
|
| `(bar boing) => false
|
|
| `(bar baz) => true
|
|
| _ => false
|