Idris2/tests/idris2/reg032/recupdate.idr

7 lines
103 B
Idris

record R (a : Type) where
constructor MkR
x : a
rmap : (a -> b) -> R a -> R b
rmap f = { x $= f }