Fix a bug in RtClosureInspect.cvReconstructType.
authorPepe Iborra <mnislaih@gmail.com>
Wed, 29 Aug 2007 17:48:42 +0000 (17:48 +0000)
committerPepe Iborra <mnislaih@gmail.com>
Wed, 29 Aug 2007 17:48:42 +0000 (17:48 +0000)
Test is print025

compiler/ghci/RtClosureInspect.hs

index e68bf88..dbc65d2 100644 (file)
@@ -640,7 +640,8 @@ cvReconstructType hsc_env force mb_ty hval = runTR_maybe hsc_env $ do
             (signatureType,_) <- instScheme(dataConRepType dc) 
             addConstraint myType signatureType
             return $ [ appArr (\e->(t,e)) (ptrs clos) i
-                       | (i,t) <- drop extra_args $ zip [0..] subTtypes]
+                       | (i,t) <- drop extra_args $ 
+                                     zip [0..] (filter isPointed subTtypes)]
       otherwise -> return []
 
      -- This helper computes the difference between a base type t and the