X-Git-Url: http://git.megacz.com/?a=blobdiff_plain;ds=sidebyside;f=compiler%2Fghci%2FRtClosureInspect.hs;h=509eb996fc69743de88f6fee17a760916120e269;hb=8c2fd74094dc533bf3256158325e3f091e57e5d2;hp=d3423373f4bdaa6c4db91b1a6ed9d9610964adf4;hpb=1363f4121ceaa38ac50eac42381b976f89d5ea96;p=ghc-hetmet.git diff --git a/compiler/ghci/RtClosureInspect.hs b/compiler/ghci/RtClosureInspect.hs index d342337..509eb99 100644 --- a/compiler/ghci/RtClosureInspect.hs +++ b/compiler/ghci/RtClosureInspect.hs @@ -386,7 +386,7 @@ ppr_termM1 NewtypeWrap{} = panic "ppr_termM1 - NewtypeWrap" pprNewtypeWrap y p NewtypeWrap{ty=ty, wrapped_term=t} | Just (tc,_) <- splitNewTyConApp_maybe ty , ASSERT(isNewTyCon tc) True - , Just new_dc <- maybeTyConSingleCon tc = do + , Just new_dc <- tyConSingleDataCon_maybe tc = do real_term <- y max_prec t return$ cparen (p >= app_prec) (ppr new_dc <+> real_term) pprNewtypeWrap _ _ _ = panic "pprNewtypeWrap" @@ -646,7 +646,7 @@ cvObtainTerm hsc_env bound force mb_ty hval = runTR hsc_env $ do (signatureType,_) <- instScheme(dataConRepType dc) addConstraint myType signatureType subTermsP <- sequence $ drop extra_args - -- ^^^ all extra arguments are pointed + -- \^^^ all extra arguments are pointed [ appArr (go (pred bound) tv t) (ptrs clos) i | (i,tv,t) <- zip3 [0..] subTermTvs subTtypesP] let unboxeds = extractUnboxed subTtypesNP clos @@ -682,7 +682,7 @@ cvObtainTerm hsc_env bound force mb_ty hval = runTR hsc_env $ do | Just (tc, args) <- splitNewTyConApp_maybe ty , isNewTyCon tc , wrapped_type <- newTyConInstRhs tc args - , Just dc <- maybeTyConSingleCon tc + , Just dc <- tyConSingleDataCon_maybe tc , t' <- expandNewtypes t{ ty = wrapped_type , subTerms = map expandNewtypes tt } = NewtypeWrap ty (Right dc) t'