Commit dcecd7a5 authored by Simon Marlow's avatar Simon Marlow

fix closure_sizeW_() for AP closures

Since thunks grew an extra padding word in GHC 6.6, closure_sizeW()
has been wrong for AP closures because it assumed compatible layout
between PAPs and APs.  One symptom is that the compacting GC would
crash if it encountered an AP.  APs conly crop up in GHCi or
when using asynchronous exceptions.

Fixes #1010
parent 7b60a250
......@@ -392,6 +392,7 @@ closure_sizeW_ (StgClosure *p, StgInfoTable *info)
case AP_STACK:
return ap_stack_sizeW((StgAP_STACK *)p);
case AP:
return ap_sizeW((StgAP *)p);
case PAP:
return pap_sizeW((StgPAP *)p);
case IND:
......
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