• simonpj@microsoft.com's avatar
    Improve liberate-case to take account of coercions · 21174275
    simonpj@microsoft.com authored
    Note [Scrutinee with cast]
    Consider this:
        f = \ t -> case (v `cast` co) of
    	         V a b -> a : f t
    Exactly the same optimistaion (unrolling one call to f) will work here, 
    despite the cast.  See mk_alt_env in the Case branch of libCase.
    This patch does the job.  For a change, it was really easy.