{-# LANGUAGE CPP #-}
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE FlexibleInstances #-}
{-# LANGUAGE FunctionalDependencies #-}
{-# LANGUAGE ScopedTypeVariables #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# LANGUAGE UndecidableInstances #-}
#ifdef USE_REFLEX_OPTIMIZER
{-# OPTIONS_GHC -fplugin=Reflex.Optimizer #-}
#endif
module Reflex.PostBuild.Class
( PostBuild (..)
) where
import Reflex.Class
import Control.Monad.Reader
import Control.Monad.State
import qualified Control.Monad.State.Strict as Strict
class (Reflex t, Monad m) => PostBuild t m | m -> t where
getPostBuild :: m (Event t ())
instance PostBuild t m => PostBuild t (ReaderT r m) where
getPostBuild = lift getPostBuild
instance PostBuild t m => PostBuild t (StateT s m) where
getPostBuild = lift getPostBuild
instance PostBuild t m => PostBuild t (Strict.StateT s m) where
getPostBuild = lift getPostBuild