summaryrefslogtreecommitdiff
path: root/compiler/codeGen
diff options
context:
space:
mode:
Diffstat (limited to 'compiler/codeGen')
-rw-r--r--compiler/codeGen/ClosureInfo.lhs6
-rw-r--r--compiler/codeGen/StgCmmClosure.hs6
2 files changed, 6 insertions, 6 deletions
diff --git a/compiler/codeGen/ClosureInfo.lhs b/compiler/codeGen/ClosureInfo.lhs
index 60f1bda7f5..8bfbfed0bc 100644
--- a/compiler/codeGen/ClosureInfo.lhs
+++ b/compiler/codeGen/ClosureInfo.lhs
@@ -268,9 +268,9 @@ might_be_a_function :: Type -> Bool
-- Return False only if we are *sure* it's a data type
-- Look through newtypes etc as much as poss
might_be_a_function ty
- = case splitTyConApp_maybe (repType ty) of
- Just (tc, _) -> not (isDataTyCon tc)
- Nothing -> True
+ = case tyConAppTyCon_maybe (repType ty) of
+ Just tc -> not (isDataTyCon tc)
+ Nothing -> True
\end{code}
@mkConLFInfo@ is similar, for constructors.
diff --git a/compiler/codeGen/StgCmmClosure.hs b/compiler/codeGen/StgCmmClosure.hs
index 2492bafc6c..daaf021f03 100644
--- a/compiler/codeGen/StgCmmClosure.hs
+++ b/compiler/codeGen/StgCmmClosure.hs
@@ -255,9 +255,9 @@ might_be_a_function :: Type -> Bool
-- Return False only if we are *sure* it's a data type
-- Look through newtypes etc as much as poss
might_be_a_function ty
- = case splitTyConApp_maybe (repType ty) of
- Just (tc, _) -> not (isDataTyCon tc)
- Nothing -> True
+ = case tyConAppTyCon_maybe (repType ty) of
+ Just tc -> not (isDataTyCon tc)
+ Nothing -> True
-------------
mkConLFInfo :: DataCon -> LambdaFormInfo