Moves the `@[coe]` attribute and associated elaborators/delaborators from Std to Lean. --------- Co-authored-by: Leonardo de Moura <leomoura@amazon.com>
11 lines
157 B
Text
11 lines
157 B
Text
@[coe] def f (n : Nat) : String :=
|
|
toString n
|
|
|
|
#check f 10
|
|
|
|
instance : Coe Nat String where
|
|
coe := f
|
|
|
|
def g (n : String) := n
|
|
|
|
#check fun x : Nat => g x
|