Follow-up from "Fix the binder-swap transformation in OccurAnal"
The following discussion from !5351 (closed) should be addressed:
-
@sgraf812 started a discussion: (+1 comment) This is all very similar to
GHC.Types.Unique.SDFM.UniqSDFM
, except that-
UniqSDFM
is deterministic, which means we lose performance if we switch to it -
UniqSDFM
isn't concerned about coercions at the moment
(1) is easily rectified by extracting an internal type class for
emptyUFM
,lookupUFM
andextendUFM
so that we can share the implementations.(2) is something that the pattern-match checker should have done for a long time anyway; currently we just discard coercions, which is a bug waiting to happen.
-
I agreed to pick up on this at some point.