Update `PrettyCooked`
Opened this issue · 2 comments
mmontin commented
At the moment, our PrettyCooked
features suffers from small inaccuracies:
- module
Pretty.Cooked
is far too long - we sometimes use
PP.pretty
instead ofprettyCookedOpts
- some
PrettyCooked
instances are located inPretty.Class
, some others inPretty.Cooked
and the reason for this separation is unclear. - some
PrettyCooked
instances are actually written as instances, while others are functions namedprettyXXX
but are basically instances. This can lead to repeated code if one does not realize an instance is here but is not actually written as such. PrettyCooked
has it ownhashable
type class which could maybe be factored withtoScriptHash
to some extent (see #424)
In addition, there could be some improvements:
- code can be factored (for example for redeemers)
- we could provide some automation to deduce PrettyCooked instances
mmontin commented
what was the thought process behind centralizing all pretty cooked instances in dedicated modules? I find it very prone to circular dependencies issues.