lean4-htt/tests/lean/run/showTests.lean
Leonardo de Moura 474f1a4d39 feat: try to unify show type and expected type
The goal is to address the regression
```
example : (0 : Nat) + 0 = 0 :=
  show 0 + 0 = 0 from rfl
```
introduced by fedf235cba

Note that we should only *try to* unify the types. Otherwise, we would
produce another regression.
```
example : Int :=
  show Nat from 0
```

cc @kha
2023-01-06 08:48:48 -08:00

11 lines
229 B
Text

example : (0 : Nat) + 0 = 0 :=
show 0 + 0 = 0 from rfl
example : (0 : Int) + 0 = 0 :=
show 0 + 0 = 0 from rfl
example : Int :=
show Nat from 0
example (x : Nat) : (x + 0) + y = x + y := by
rw [show x + 0 = x from rfl]