Files
lean4/tests/server_interactive/2058.lean
Garmelon a3cb39eac9 chore: migrate more tests to new test suite (#12809)
This PR migrates most remaining tests to the new test suite. It also
completes the migration of directories like `tests/lean/run`, meaning
that PRs trying to add tests to those old directories will now fail.
2026-03-06 16:52:01 +00:00

32 lines
648 B
Lean4

/-!
# Localized error messages with unassigned metavariables
-/
set_option pp.mvars false
/-!
Test: now reports that the universe levels are not assigned at the 'let' rather than an error on the `example` command.
-/
def foo : IO Unit := do
let x : PUnit := PUnit.unit
--^ collectDiagnostics
pure ()
/-!
Test: Works for `fun` binders too.
-/
example : Nat := (fun x : PUnit => 2) PUnit.unit
--^ collectDiagnostics
/-!
Test: A failure not in a binder, right now reports an error on `example` since there's no other location information.
-/
example : Nat := Function.const _ 2 @id
--^ collectDiagnostics