diff --git a/hpqtypes.cabal b/hpqtypes.cabal
--- a/hpqtypes.cabal
+++ b/hpqtypes.cabal
@@ -1,5 +1,5 @@
 name:                hpqtypes
-version:             1.2.4
+version:             1.2.5
 synopsis:            Haskell bindings to libpqtypes
 
 description:         Efficient and easy-to-use bindings to (slightly modified)
diff --git a/src/Database/PostgreSQL/PQTypes/Internal/Monad.hs b/src/Database/PostgreSQL/PQTypes/Internal/Monad.hs
--- a/src/Database/PostgreSQL/PQTypes/Internal/Monad.hs
+++ b/src/Database/PostgreSQL/PQTypes/Internal/Monad.hs
@@ -1,6 +1,6 @@
 {-# LANGUAGE FlexibleContexts, FlexibleInstances, GeneralizedNewtypeDeriving
   , MultiParamTypeClasses, ScopedTypeVariables, TypeFamilies
-  , UndecidableInstances #-}
+  , UndecidableInstances, CPP #-}
 module Database.PostgreSQL.PQTypes.Internal.Monad (
     DBT(..)
   , runDBT
@@ -90,18 +90,34 @@
 ----------------------------------------
 
 instance MonadTransControl DBT where
+#if MIN_VERSION_monad_control(1,0,0)
+  type StT DBT a = StT InnerDBT a
+  liftWith = defaultLiftWith DBT unDBT
+  restoreT = defaultRestoreT DBT
+  {-# INLINE liftWith #-}
+  {-# INLINE restoreT #-}
+#else
   newtype StT DBT a = StDBT { unStDBT :: StT InnerDBT a }
   liftWith = defaultLiftWith DBT unDBT StDBT
   restoreT = defaultRestoreT DBT unStDBT
   {-# INLINE liftWith #-}
   {-# INLINE restoreT #-}
+#endif
 
 instance MonadBaseControl b m => MonadBaseControl b (DBT m) where
+#if MIN_VERSION_monad_control(1,0,0)
+  type StM (DBT m) a = ComposeSt DBT m a
+  liftBaseWith = defaultLiftBaseWith
+  restoreM     = defaultRestoreM
+  {-# INLINE liftBaseWith #-}
+  {-# INLINE restoreM #-}
+#else
   newtype StM (DBT m) a = StMDBT { unStMDBT :: ComposeSt DBT m a }
   liftBaseWith = defaultLiftBaseWith StMDBT
   restoreM     = defaultRestoreM unStMDBT
   {-# INLINE liftBaseWith #-}
   {-# INLINE restoreM #-}
+#endif
 
 -- | When given 'DBException' or 'ExitCode', throw it
 -- immediately. Otherwise wrap it in 'DBException' first.
diff --git a/test/Main.hs b/test/Main.hs
--- a/test/Main.hs
+++ b/test/Main.hs
@@ -1,7 +1,7 @@
 {-# OPTIONS_GHC -fno-warn-orphans #-}
 {-# LANGUAGE BangPatterns, DeriveDataTypeable, FlexibleContexts
   , GeneralizedNewtypeDeriving, MultiParamTypeClasses, OverloadedStrings
-  , ScopedTypeVariables, TypeFamilies, UndecidableInstances #-}
+  , ScopedTypeVariables, TypeFamilies, UndecidableInstances, CPP #-}
 module Main where
 
 import Control.Applicative
@@ -39,10 +39,17 @@
   deriving (Applicative, Functor, Monad, MonadBase IO, MonadCatch, MonadDB, MonadMask, MonadThrow)
 
 instance MonadBaseControl IO TestEnv where
+#if MIN_VERSION_monad_control(1,0,0)
+  type StM TestEnv a = StM InnerTestEnv a
+  liftBaseWith f = liftBaseWith $ \run ->
+                         f $ run
+  restoreM = restoreM
+#else
   newtype StM TestEnv a = StTestEnv { unStTestEnv :: StM InnerTestEnv a }
   liftBaseWith f = TestEnv $ liftBaseWith $ \run ->
                          f $ liftM StTestEnv . run . unTestEnv
   restoreM = TestEnv . restoreM . unStTestEnv
+#endif
 
 withStdGen :: (StdGen -> r) -> TestEnv r
 withStdGen f = do
