Fix a sanity check; fixes #3089
[ghc-hetmet.git] / rts / Sanity.c
index 02d81ed..49bbff7 100644 (file)
 
 #ifdef DEBUG                                                   /* whole file */
 
-#include "RtsFlags.h"
 #include "RtsUtils.h"
-#include "BlockAlloc.h"
+#include "sm/Storage.h"
+#include "sm/BlockAlloc.h"
 #include "Sanity.h"
-#include "MBlock.h"
-#include "Storage.h"
 #include "Schedule.h"
 #include "Apply.h"
+#include "Printer.h"
 
 /* -----------------------------------------------------------------------------
    Forward decls.
@@ -237,7 +236,7 @@ checkPAP (StgClosure *tagged_fun, StgClosure** payload, StgWord n_args)
        break;
     }
 
-    ASSERT(fun_info->f.arity > TAG_MASK ? GET_CLOSURE_TAG(tagged_fun) == 1
+    ASSERT(fun_info->f.arity > TAG_MASK ? GET_CLOSURE_TAG(tagged_fun) == 0
            : GET_CLOSURE_TAG(tagged_fun) == fun_info->f.arity);
 }