Commit 8f48fdc8 authored by Simon Peyton Jones's avatar Simon Peyton Jones

Use varToCoreExpr in mkWWcpr_help

Lacking this cuased Trac #10658.
The fix is easy; it was a simple omission.
parent e0a3c441
......@@ -635,7 +635,9 @@ mkWWcpr_help (data_con, inst_tys, arg_tys, co)
; return ( True
, \ wkr_call -> Case wkr_call arg (exprType con_app) [(DEFAULT, [], con_app)]
, \ body -> mkUnpackCase body co work_uniq data_con [arg] (Var arg)
, \ body -> mkUnpackCase body co work_uniq data_con [arg] (varToCoreExpr arg)
-- varToCoreExpr important here: arg can be a coercion
-- Lacking this caused Trac #10658
, arg_ty1 ) }
| otherwise -- The general case
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment