hnix-0.6.1: Haskell implementation of the Nix language

Safe HaskellSafe
LanguageHaskell2010

Nix.Value.Monad

Documentation

class MonadValue v m where Source #

Methods

defer :: m v -> m v Source #

demand :: v -> (v -> m r) -> m r Source #

inform :: v -> (m v -> m v) -> m v Source #

If v is a thunk, inform allows us to modify the action to be peformed by the thunk, perhaps by enriching it with scpoe info, for example.

Instances
(MonadThunkId m, MonadAtomicRef m, MonadCatch m) => MonadValue (Symbolic m) m Source # 
Instance details

Defined in Nix.Lint

Methods

defer :: m (Symbolic m) -> m (Symbolic m) Source #

demand :: Symbolic m -> (Symbolic m -> m r) -> m r Source #

inform :: Symbolic m -> (m (Symbolic m) -> m (Symbolic m)) -> m (Symbolic m) Source #

(MonadAtomicRef m, MonadCatch m, Typeable m, MonadReader (Context m (StdValue m)) m, MonadThunkId m) => MonadValue (StdValue m) m Source # 
Instance details

Defined in Nix.Standard

Methods

defer :: m (StdValue m) -> m (StdValue m) Source #

demand :: StdValue m -> (StdValue m -> m r) -> m r Source #

inform :: StdValue m -> (m (StdValue m) -> m (StdValue m)) -> m (StdValue m) Source #