Missing instance of MonadFix for Q
Q is capable of being an instance of MonadFix. The definition of mfix is the same as fixIO except that the MVar handling is wrapped in runIO.
instance MonadFix Q where
mfix k = do
m <- runIO newEmptyMVar
ans <- runIO (unsafeInterleaveIO (takeMVar m))
result <- k ans
runIO (putMVar m result)
pure result
Trac metadata
| Trac field | Value |
|---|---|
| Version | |
| Type | FeatureRequest |
| TypeOfFailure | OtherFailure |
| Priority | normal |
| Resolution | Unresolved |
| Component | Template Haskell |
| Test case | |
| Differential revisions | |
| BlockedBy | |
| Related | |
| Blocking | |
| CC | |
| Operating system | |
| Architecture |