git.iko.soy/typeable/postgresql-simple
on master help sign in
Remove transformer dependency (for now?)
commit2bb457a743f8838acb0a8b90b768d573e458536d authorLeon P Smith <leon@melding-monads.com> dateSun 25 Dec 2011, 01:52 (15 years ago) parent18ca588
2 files changed+4−6
postgresql-simple.cabal+1−2 src/Database/PostgreSQL/Simple/Implementation.hs+3−4
postgresql-simple.cabal+1−2
@@ -45,8 +45,7 @@ Library
4545 pcre-light,
4646 old-locale,
4747 text >= 0.11.0.2,
48− time,
49− transformers
48+ time
5049 -- Modules not exported by this package.
5150 -- Other-modules:
5251
src/Database/PostgreSQL/Simple/Implementation.hs+3−4
@@ -6,7 +6,6 @@ import Prelude hiding (catch)
66
77import Control.Applicative
88import Control.Exception
9−import Control.Monad.IO.Class (MonadIO(liftIO))
109import Control.Concurrent.MVar
1110import Data.ByteString(ByteString)
1211import qualified Data.IntMap as IntMap
@@ -100,11 +99,11 @@ defaultConnectInfo = ConnectInfo {
10099
101100-- | Connect with the given username to the given database. Will throw
102101-- an exception if it cannot connect.
103−connect :: MonadIO m => ConnectInfo -> m Connection
102+connect :: ConnectInfo -> IO Connection
104103connect = connectPostgreSQL . postgreSQLConnectionString
105104
106−connectPostgreSQL :: MonadIO m => ByteString -> m Connection
107−connectPostgreSQL connstr = liftIO $ do
105+connectPostgreSQL :: ByteString -> IO Connection
106+connectPostgreSQL connstr = do
108107 conn <- PQ.connectdb connstr
109108 connectionHandle <- newMVar (Just conn)
110109 connectionObjects <- newMVar (IntMap.empty)