• eir@cis.upenn.edu's avatar
    Revise implementation of overlapping type family instances. · 569b2652
    eir@cis.upenn.edu authored
    This commit changes the syntax and story around overlapping type
    family instances. Before, we had "unbranched" instances and
    "branched" instances. Now, we have closed type families and
    open ones.
    The behavior of open families is completely unchanged. In particular,
    coincident overlap of open type family instances still works, despite
    emails to the contrary.
    A closed type family is declared like this:
    > type family F a where
    >   F Int = Bool
    >   F a   = Char
    The equations are tried in order, from top to bottom, subject to
    certain constraints, as described in the user manual. It is not
    allowed to declare an instance of a closed family.
TcIface.lhs 65.1 KB