Write short and concise contexts based on generics.
Instead of writing boiler-plate standalone deriving clauses in the form of
deriving instance [Various Eq Constraints Here] => Instance Eq MyTypeWith generic-constraints you can use
deriving instance Constraints MyType Eq => Eq MyTypeOr, using TH, simply
makeDeriving ''Eq ''MyTypeAnd for several classes and types:
makeDerivings [''Eq, ''Ord, ''Show] [''MyType, ''MyOtherType]This library was extracted from the one-liner library by Sjoerd Visscher and Xia Li-yao.