Skip to content

Commit

Permalink
Compatibility with cond >= 0.5 (#13)
Browse files Browse the repository at this point in the history
  • Loading branch information
arybczak authored Nov 23, 2023
1 parent f7b99fb commit 3e505e9
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
2 changes: 1 addition & 1 deletion scrive-prelude.cabal
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
cabal-version: 3.0
name: scrive-prelude
version: 1.0.2.0
version: 1.0.2.1
author: Scrive AB
maintainer: Scrive AB
copyright: 2021
Expand Down
3 changes: 3 additions & 0 deletions src/Prelude.hs
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
{-# LANGUAGE CPP #-}
{-# LANGUAGE PackageImports #-}
{-# OPTIONS_GHC -fno-warn-orphans #-}

Expand Down Expand Up @@ -167,6 +168,7 @@ import "base" Prelude hiding
)
import qualified "base" Prelude as P hiding (fail)

#if !MIN_VERSION_cond(0,5,0)
-- | Boolean algebra of functions.
instance Boolean b => Boolean (a -> b) where
true = const true
Expand All @@ -177,6 +179,7 @@ instance Boolean b => Boolean (a -> b) where
xor = liftA2 xor
(-->) = liftA2 (-->)
(<-->) = liftA2 (<-->)
#endif

instance FromJSValue Text where
fromJSValue = fmap T.pack . fromJSValue
Expand Down

0 comments on commit 3e505e9

Please sign in to comment.