Skip to content

Commit d5c76c9

Browse files
committed
Standard: instance MonadThunk (StdThunk m) m (StdValue m): inline it
It actually just protects a thunk from being seen as Cited in the code. It is just a type boundary for thunks.
1 parent 2b7938e commit d5c76c9

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

src/Nix/Standard.hs

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -142,27 +142,32 @@ instance
142142
:: m (StdValue m)
143143
-> m (StdThunk m)
144144
thunk = fmap coerce . thunk @(CitedStdThunk m)
145+
{-# inline thunk #-}
145146

146147
query
147148
:: m (StdValue m)
148149
-> StdThunk m
149150
-> m (StdValue m)
150151
query b = query @(CitedStdThunk m) b . coerce
152+
{-# inline query #-}
151153

152154
force
153155
:: StdThunk m
154156
-> m (StdValue m)
155157
force = force @(CitedStdThunk m) . coerce
158+
{-# inline force #-}
156159

157160
forceEff
158161
:: StdThunk m
159162
-> m (StdValue m)
160163
forceEff = forceEff @(CitedStdThunk m) . coerce
164+
{-# inline forceEff #-}
161165

162166
further
163167
:: StdThunk m
164168
-> m (StdThunk m)
165169
further = fmap coerce . further @(CitedStdThunk m) . coerce
170+
{-# inline further #-}
166171

167172

168173
-- * @instance MonadThunkF@ (Kleisli functor HOFs)

0 commit comments

Comments
 (0)