Note [Coherence and specialisation: overview]

GHC/Core/InstEnv.hs:816 compiler

GHC's specialiser relies on the Coherence Assumption: that if
      d1 :: C tys
      d2 :: C tys
then the dictionary d1 can be used in place of d2 and vice versa; it is as if
(C tys) is a singleton type.  If d1 and d2 are interchangeable, we say that
they constitute /canonical evidence/ for (C tys).  We have a special data type,
`CanonoicalEvidence`, for recording whether evidence is canonical.

Let's use this example
  class C a where { op :: a -> Int }
  instance                     C [a]         where {...}   -- (I1)
  instance {-# OVERLAPPING #

References 0

This Note does not link to any other.

Referenced by 9