diff options
author | Simon Peyton Jones <simonpj@microsoft.com> | 2011-08-03 16:14:26 +0100 |
---|---|---|
committer | Simon Peyton Jones <simonpj@microsoft.com> | 2011-08-03 16:14:26 +0100 |
commit | 1bcd32b8e0f252d3b830c961184dab9d8b61dba9 (patch) | |
tree | 0d6315c9e1a06c4801d89be85c21fa95df97b34e /compiler/specialise/SpecConstr.lhs | |
parent | c679ce14814a044d6607b31b8e65e9c7ea17af81 (diff) | |
download | haskell-1bcd32b8e0f252d3b830c961184dab9d8b61dba9.tar.gz |
Add Type.tyConAppTyCon_maybe and tyConAppArgs_maybe, and use them
These turn out to be a useful special case of splitTyConApp_maybe.
A refactoring only; no change in behaviour
Diffstat (limited to 'compiler/specialise/SpecConstr.lhs')
-rw-r--r-- | compiler/specialise/SpecConstr.lhs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/compiler/specialise/SpecConstr.lhs b/compiler/specialise/SpecConstr.lhs index 6cc05a3dc6..f126bdac47 100644 --- a/compiler/specialise/SpecConstr.lhs +++ b/compiler/specialise/SpecConstr.lhs @@ -809,9 +809,9 @@ forceSpecBndr _ _ = False ignoreDataCon env dc = ignoreTyCon env (dataConTyCon dc) ignoreType env ty - = case splitTyConApp_maybe ty of - Just (tycon, _) -> ignoreTyCon env tycon - _ -> False + = case tyConAppTyCon_maybe ty of + Just tycon -> ignoreTyCon env tycon + _ -> False ignoreTyCon :: ScEnv -> TyCon -> Bool ignoreTyCon env tycon |