make HandshakeM an instance of Applicative.
This commit is contained in:
parent
2a09d51ba5
commit
a223673eed
1 changed files with 2 additions and 2 deletions
|
@ -48,7 +48,7 @@ import Network.TLS.Crypto
|
||||||
import Network.TLS.Cipher
|
import Network.TLS.Cipher
|
||||||
import Network.TLS.Compression
|
import Network.TLS.Compression
|
||||||
import Network.TLS.Types
|
import Network.TLS.Types
|
||||||
import Control.Applicative ((<$>))
|
import Control.Applicative (Applicative, (<$>))
|
||||||
import Control.Monad.State
|
import Control.Monad.State
|
||||||
import Data.X509 (CertificateChain)
|
import Data.X509 (CertificateChain)
|
||||||
|
|
||||||
|
@ -78,7 +78,7 @@ type ClientCertRequestData = ([CertificateType],
|
||||||
[DistinguishedName])
|
[DistinguishedName])
|
||||||
|
|
||||||
newtype HandshakeM a = HandshakeM { runHandshakeM :: State HandshakeState a }
|
newtype HandshakeM a = HandshakeM { runHandshakeM :: State HandshakeState a }
|
||||||
deriving (Functor, Monad)
|
deriving (Functor, Applicative, Monad)
|
||||||
|
|
||||||
instance MonadState HandshakeState HandshakeM where
|
instance MonadState HandshakeState HandshakeM where
|
||||||
put x = HandshakeM (put x)
|
put x = HandshakeM (put x)
|
||||||
|
|
Loading…
Reference in a new issue