From 63f881caacf7b5c13c1bd41b2edc2510b59dfc01 Mon Sep 17 00:00:00 2001 From: Anton-Latukha Date: Tue, 23 Feb 2021 18:30:08 +0200 Subject: [PATCH] Nix.Standard: add instance sign to `queryM` --- src/Nix/Standard.hs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/Nix/Standard.hs b/src/Nix/Standard.hs index 56ea22f79..5f6be3718 100644 --- a/src/Nix/Standard.hs +++ b/src/Nix/Standard.hs @@ -133,6 +133,7 @@ instance ( MonadAtomicRef m thunkId :: StdThunk m -> ThunkId m thunkId = thunkId . _stdCited . _stdThunk + queryM :: StdThunk m -> m r -> (StdValue m -> m r) -> m r queryM x b f = queryM (_stdCited (_stdThunk x)) b f force :: (StdValue m -> m r) -> StdThunk m -> m r @@ -142,7 +143,7 @@ instance ( MonadAtomicRef m forceEff f t = forceEff f (_stdCited $ _stdThunk t) further :: StdThunk m -> (m (StdValue m) -> m (StdValue m)) -> m (StdThunk m) - further = (fmap (StdThunk . StdCited) .) . further . _stdCited . _stdThunk + further t f = ((fmap (StdThunk . StdCited) .) $ further $ _stdCited $ _stdThunk t) f instance ( MonadAtomicRef m , MonadCatch m