diff options
author | Simon Peyton Jones <simonpj@microsoft.com> | 2015-07-20 23:34:31 +0100 |
---|---|---|
committer | Simon Peyton Jones <simonpj@microsoft.com> | 2015-07-21 13:21:30 +0100 |
commit | 8f48fdc8f97c1f6f59e12a703e380d27760810b1 (patch) | |
tree | f2a52ec7174a3352d8c3eb48d7fb55b65bdb5b2f /compiler/stranal | |
parent | e0a3c441412923bb8b422281cf2e0f8f2841d6c1 (diff) | |
download | haskell-8f48fdc8f97c1f6f59e12a703e380d27760810b1.tar.gz |
Use varToCoreExpr in mkWWcpr_help
Lacking this cuased Trac #10658.
The fix is easy; it was a simple omission.
Diffstat (limited to 'compiler/stranal')
-rw-r--r-- | compiler/stranal/WwLib.hs | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/compiler/stranal/WwLib.hs b/compiler/stranal/WwLib.hs index 304a3cbacb..b442f3d9a9 100644 --- a/compiler/stranal/WwLib.hs +++ b/compiler/stranal/WwLib.hs @@ -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 |