IntersectMBO / ouroboros-consensus

Implementation of a Consensus Layer for the Ouroboros family of protocols
https://ouroboros-consensus.cardano.intersectmbo.org
Apache License 2.0
36 stars 23 forks source link

`QueryHF` code is excessively verbose #1318

Open jasagredo opened 1 week ago

jasagredo commented 1 week ago
          All of these function definitions seem excessively verbose.

Perhaps even just factoring out a reusable combinator for the Byron-versus-Shelley split would reduce the noise by approximately 2.5x?

_Originally posted by @nfrisby in https://github.com/IntersectMBO/ouroboros-consensus/pull/1267#discussion_r1828563684_

As @amesgen also suggested, we could use some TH helper. Same applies to Cardano/Ledger.hs instances.

Let's do this after the merge.