• Simon Peyton Jones's avatar
    Fix exprIsHNF (Trac #11248) · 3c060f36
    Simon Peyton Jones authored
    Blimey!  CoreUtils.exprIsHNFlike had not one but two bugs.
    
     * is_hnf_like treated coercion args like type args
       (result: exprIsHNF might wrongly say True)
    
     * app_is_value treated type args like value args
       (result: exprIsHNF might wrongly say False)
    
    Bizarre.  This goes back to at least 2012. It's amazing that it
    hasn't caused more trouble.
    
    It was discovered by a Lint error when compiling Trac #11248 with -O.
    3c060f36
CoreUtils.hs 86.1 KB