monadiccp-0.7.7: Constraint Programming

Safe HaskellNone
LanguageHaskell98

Control.Search.Generator

Documentation

mmap :: (FMonadT t, MonadInfoT t, Monad m, Monad n, MonadInfo m) => (forall x. m x -> n x) -> t m a -> t n a Source #

newtype VarId Source #

Constructors

VarId Int 

Instances

Eq VarId Source # 

Methods

(==) :: VarId -> VarId -> Bool #

(/=) :: VarId -> VarId -> Bool #

Ord VarId Source # 

Methods

compare :: VarId -> VarId -> Ordering #

(<) :: VarId -> VarId -> Bool #

(<=) :: VarId -> VarId -> Bool #

(>) :: VarId -> VarId -> Bool #

(>=) :: VarId -> VarId -> Bool #

max :: VarId -> VarId -> VarId #

min :: VarId -> VarId -> VarId #

Show VarId Source # 

Methods

showsPrec :: Int -> VarId -> ShowS #

show :: VarId -> String #

showList :: [VarId] -> ShowS #

mapE :: (HookStatsM m, HookStatsM n) => (forall x. m x -> n x) -> Eval m -> Eval n Source #

inite :: Monad m => [(String, Info -> m Value)] -> Info -> m Statement Source #

seqSwitch :: ReaderM SeqPos m => m a -> m a -> m a Source #

class Monad m => VarInfoM m where Source #

Minimal complete definition

lookupVarInfo, setVarInfo

Methods

lookupVarInfo :: VarId -> m Info Source #

setVarInfo :: VarId -> Info -> m () Source #

Instances

(VarInfoM m, FMonadT t) => VarInfoM (t m) Source # 

Methods

lookupVarInfo :: VarId -> t m Info Source #

setVarInfo :: VarId -> Info -> t m () Source #

type MkEval m = Evalable m => Eval m -> State Int (Eval m) Source #

class (VarInfoM m, HookStatsM m, MonadInfo m, MemoM m, GenModeM m, Functor m) => Evalable m Source #

Instances

(VarInfoM m, HookStatsM m, MonadInfo m, MemoM m, GenModeM m, Functor m) => Evalable m Source # 

data SeqPos Source #

Constructors

OutS 
FirstS 
SecondS 

Instances

data Search Source #

Constructors

(FMonadT t2, MonadInfoT t2) => Search 

Fields

(@.) :: Monad m => m (a -> b) -> m a -> m b Source #

(@$) :: Monad m => (a -> b) -> m a -> m b Source #

(@++@) :: ([a1], [a2]) -> ([a1], [a2]) -> ([a1], [a2]) Source #

numSwitch :: ReaderM t m => (t -> m b) -> m b Source #

data SearchCombiner Source #

Constructors

(FMonadT t1, FMonadT t2, MonadInfoT t1, MonadInfoT t2) => SearchCombiner 

Fields

  • runner :: forall m x. Evalable m => (t1 :> t2) m x -> m x
     
  • elems :: [SearchCombinerElem t1 t2]
     

extractCombiners :: (Evalable m, FMonadT t', MonadInfoT t', FMonadT t1, MonadInfoT t1, FMonadT t2, MonadInfoT t2) => [SearchCombinerElem t1 t2] -> Eval (t' ((t1 :> t2) m)) -> State Int [Eval (t' ((t1 :> t2) m))] Source #

memo :: Memoable m => String -> Info -> m -> m Source #

memoLoop :: (GenModeM m, MemoM m, MonadInfo m, HookStatsM m, VarInfoM m) => Eval m -> Eval m Source #

rReaderT :: (Show s, MemoM m) => s -> MemoReaderT s m a -> m a Source #

rp :: Pretty x => Int -> x -> String Source #

cachedClone :: (GenModeM m, MemoM m, MonadInfo m, HookStatsM m, VarInfoM m) => Info -> Info -> m Statement Source #

nextSame :: HookStatsM m => Eval m -> Info -> m Statement Source #

nextDiff :: HookStatsM m => Eval m -> Info -> m Statement Source #

pushLeft :: HookStatsM m => Eval m -> Info -> m Statement Source #

pushRight :: HookStatsM m => Eval m -> Info -> m Statement Source #

bodyE :: HookStatsM m => Eval m -> Info -> m Statement Source #

addE :: HookStatsM m => Eval m -> Info -> m Statement Source #

returnE :: HookStatsM m => Eval m -> Info -> m Statement Source #

initE :: HookStatsM m => Eval m -> Info -> m Statement Source #

failE :: HookStatsM m => Eval m -> Info -> m Statement Source #

tryE :: HookStatsM m => Eval m -> Info -> m Statement Source #

startTryE :: HookStatsM m => Eval m -> Info -> m Statement Source #

tryE_ :: HookStatsM m => Eval m -> Info -> m Statement Source #

deleteE :: HookStatsM m => Eval m -> Info -> m Statement Source #