Commit 4d71f5ee authored by mnislaih's avatar mnislaih
Browse files

Prevent the binding of unboxed things by :print

parent d31018bc
...@@ -73,8 +73,10 @@ pprintClosureCommand session bindThings force str = do ...@@ -73,8 +73,10 @@ pprintClosureCommand session bindThings force str = do
go cms id = do go cms id = do
term_ <- GHC.obtainTerm cms force id term_ <- GHC.obtainTerm cms force id
term <- tidyTermTyVars cms term_ term <- tidyTermTyVars cms term_
term' <- if not bindThings then return term term' <- if bindThings &&
else bindSuspensions cms term Just False == isUnliftedTypeKind `fmap` termType term
then bindSuspensions cms term
else return term
-- Before leaving, we compare the type obtained to see if it's more specific -- Before leaving, we compare the type obtained to see if it's more specific
-- Then, we extract a substitution, -- Then, we extract a substitution,
-- mapping the old tyvars to the reconstructed types. -- mapping the old tyvars to the reconstructed types.
......
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