Revision 78e0f701

b/src/Ganeti/Logging.hs
55 55
import Control.Monad.Error (Error(..), MonadError(..), catchError)
56 56
import Control.Monad.Reader
57 57
import qualified Control.Monad.RWS.Strict as RWSS
58
import qualified Control.Monad.State.Strict as SS
59
import Control.Monad.Trans.Identity
58 60
import Data.Monoid
59 61
import System.Log.Logger
60 62
import System.Log.Handler.Simple
......
141 143
instance MonadLog IO where
142 144
  logAt = logM rootLoggerName
143 145

  
146
instance (MonadLog m) => MonadLog (IdentityT m) where
147
  logAt p = lift . logAt p
148

  
144 149
instance (MonadLog m) => MonadLog (ReaderT r m) where
145 150
  logAt p = lift . logAt p
146 151

  
152
instance (MonadLog m) => MonadLog (SS.StateT s m) where
153
  logAt p = lift . logAt p
154

  
147 155
instance (MonadLog m, Monoid w) => MonadLog (RWSS.RWST r w s m) where
148 156
  logAt p = lift . logAt p
149 157

  

Also available in: Unified diff