plutus
plutus copied to clipboard
Add a `MINIMAL` pragma to `Ord` and check existence of other `MINIMAL` pragmas
PlutusTx.Ord.Ord lacks a MINIMAL pragma meaning it's easy to cause an infinite loop by defining an instance of this class. We should simply take the pragma from base (where that code is stolen from):
{-# MINIMAL compare | (<=) #-}
and check existence of MINIMAL pragmas for all the other type classes where such a pragma applies.