Open istathar opened 1 year ago
A long while ago we added invalid in Core.Program to make it clear when you'd hit an illegal state (when in monadic context). https://github.com/aesiniath/unbeliever/blob/e55e65fd8278e81e374d6e501335227078d257df/core-program/lib/Core/Program/Execute.hs#L1103-L1108 is the current implementation
invalid
I bet that could be done better.
At the very least an HasCallStack => constraint might be good, but is there something better than using error here? MonadFail fail?
error
fail
A long while ago we added
invalid
in Core.Program to make it clear when you'd hit an illegal state (when in monadic context). https://github.com/aesiniath/unbeliever/blob/e55e65fd8278e81e374d6e501335227078d257df/core-program/lib/Core/Program/Execute.hs#L1103-L1108 is the current implementationI bet that could be done better.
At the very least an HasCallStack => constraint might be good, but is there something better than using
error
here? MonadFailfail
?