• simonpj@microsoft.com's avatar
    Robustify the treatement of DFunUnfolding · a90dc390
    simonpj@microsoft.com authored
    See Note [DFun unfoldings] in CoreSyn.  The issue here is that 
    you can't tell how many dictionary arguments a DFun needs just
    from looking at the Arity of the DFun Id: if the dictionary is
    represented by a newtype the arity might include the dictionary
    and value arguments of the (single) method.
    
    So we need to record the number of arguments need by the DFun
    in the DFunUnfolding itself.  Details in 
       Note [DFun unfoldings] in CoreSyn
    a90dc390
Simplify.lhs 92 KB