MonadZ3 for ReaderT
Closed this issue · 1 comments
0xd34df00d commented
I currently have
instance MonadZ3 m => MonadZ3 (ReaderT r m) where
getSolver = ReaderT $ const getSolver
getContext = ReaderT $ const getContext
in my code base which is a pretty straightforward implementation. But:
- It's an orphan instance.
- It can probably be useful for somebody else if they wish to carry additional context around
MonadZ3
.
I probably wouldn't have considered wasting time discussing this and just opened a PR with these three lines straight ahead, but I noticed 3ec14bc, so I thought it's worth double-checking if it's a desirable direction, and, if so, if it's the best way to implement this change.
So, what are your thoughts on this?
0xd34df00d commented
Actually disregard that. For some reason I thought that it'd require bringing mtl dependency back, which obviously isn't the case. Feel free to close!