mirror of
https://github.com/idris-lang/Idris2.git
synced 2024-12-11 14:23:19 +03:00
4f10bfcfd2
This is referred to in the documentation, so should be there
12 lines
241 B
Idris
12 lines
241 B
Idris
[PlusNatSemi] Semigroup Nat where
|
|
(<+>) x y = x + y
|
|
|
|
[MultNatSemi] Semigroup Nat where
|
|
(<+>) x y = x * y
|
|
|
|
[PlusNatMonoid] Monoid Nat using PlusNatSemi where
|
|
neutral = 0
|
|
|
|
[MultNatMonoid] Monoid Nat using MultNatSemi where
|
|
neutral = 1
|