Skip to content

Commit 70fee15

Browse files
committed
Add BoundedOrd instance
1 parent b776251 commit 70fee15

File tree

2 files changed

+4
-1
lines changed

2 files changed

+4
-1
lines changed

docs/Data.Lazy.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@ instance numLazy :: (Num a) => Num (Lazy a)
2929
instance eqLazy :: (Eq a) => Eq (Lazy a)
3030
instance ordLazy :: (Ord a) => Ord (Lazy a)
3131
instance boundedLazy :: (Bounded a) => Bounded (Lazy a)
32+
instance boundedOrdLazy :: (BoundedOrd a) => BoundedOrd (Lazy a)
3233
instance semigroupLazy :: (Semigroup a) => Semigroup (Lazy a)
3334
instance monoidLazy :: (Monoid a) => Monoid (Lazy a)
3435
instance booleanAlgebraLazy :: (BooleanAlgebra a) => BooleanAlgebra (Lazy a)

src/Data/Lazy.purs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,8 @@ instance boundedLazy :: (Bounded a) => Bounded (Lazy a) where
5454
top = defer \_ -> top
5555
bottom = defer \_ -> bottom
5656

57+
instance boundedOrdLazy :: (BoundedOrd a) => BoundedOrd (Lazy a)
58+
5759
instance semigroupLazy :: (Semigroup a) => Semigroup (Lazy a) where
5860
append a b = defer \_ -> force a <> force b
5961

@@ -64,7 +66,7 @@ instance booleanAlgebraLazy :: (BooleanAlgebra a) => BooleanAlgebra (Lazy a) whe
6466
conj a b = conj <$> a <*> b
6567
disj a b = disj <$> a <*> b
6668
not a = not <$> a
67-
69+
6870
instance functorLazy :: Functor Lazy where
6971
map f l = defer \_ -> f (force l)
7072

0 commit comments

Comments
 (0)