binary icon indicating copy to clipboard operation
binary copied to clipboard

MonadFix instance required

Open code5hot opened this issue 6 years ago • 0 comments
trafficstars

Hi, I need a MonadFix instance for the Put monad so I can use the length of an expressions output as a parameter to construct the expression (for example, to output the offset to the end of a header at some place within the header itself).

I attempted to write the instance of MonadFix but there is excess strictness somewhere that causes the fixedpoint to be undefined: https://github.com/code5hot/binary/commit/551591dd05e3cb7769a2d61fdc16d8f45a69b88e#commitcomment-34039617

Any suggestions on how to complete this mfix implementation?

code5hot avatar Jun 22 '19 08:06 code5hot