diff --git a/library/Hasql/Private/Decoders.hs b/library/Hasql/Private/Decoders.hs index 162e320..bd3daf2 100644 --- a/library/Hasql/Private/Decoders.hs +++ b/library/Hasql/Private/Decoders.hs @@ -458,7 +458,7 @@ element = \ case Composable decoder of composite values (rows, records). -} newtype Composite a = Composite (Composite.Composite a) - deriving (Functor, Applicative, Monad) + deriving (Functor, Applicative, Monad, MonadFail) {-| Lift a 'Value' decoder into a 'Composite' decoder for parsing of component values. diff --git a/library/Hasql/Private/Decoders/Composite.hs b/library/Hasql/Private/Decoders/Composite.hs index 3bebc90..8d40237 100644 --- a/library/Hasql/Private/Decoders/Composite.hs +++ b/library/Hasql/Private/Decoders/Composite.hs @@ -6,7 +6,7 @@ import qualified PostgreSQL.Binary.Decoding as A newtype Composite a = Composite (ReaderT Bool A.Composite a) - deriving (Functor, Applicative, Monad) + deriving (Functor, Applicative, Monad, MonadFail) {-# INLINE run #-} run :: Composite a -> Bool -> A.Value a