[commit: ghc] master: Add DebugCallStack to piResultTy (ad0037e)
git at git.haskell.org
git at git.haskell.org
Fri Jul 28 08:56:41 UTC 2017
Repository : ssh://git@git.haskell.org/ghc
On branch : master
Link : http://ghc.haskell.org/trac/ghc/changeset/ad0037ea3ea0eb9e2e693fa10f2171611c4e2217/ghc
>---------------------------------------------------------------
commit ad0037ea3ea0eb9e2e693fa10f2171611c4e2217
Author: Simon Peyton Jones <simonpj at microsoft.com>
Date: Fri Jul 28 09:29:25 2017 +0100
Add DebugCallStack to piResultTy
This was provoked by an ASSERT failure when debugging #14038,
but it's a godo idea anyway.
>---------------------------------------------------------------
ad0037ea3ea0eb9e2e693fa10f2171611c4e2217
compiler/types/Type.hs | 2 +-
compiler/types/Type.hs-boot | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/compiler/types/Type.hs b/compiler/types/Type.hs
index 1c54c44..b81192f 100644
--- a/compiler/types/Type.hs
+++ b/compiler/types/Type.hs
@@ -943,7 +943,7 @@ funArgTy ty | Just ty' <- coreView ty = funArgTy ty'
funArgTy (FunTy arg _res) = arg
funArgTy ty = pprPanic "funArgTy" (ppr ty)
-piResultTy :: Type -> Type -> Type
+piResultTy :: HasDebugCallStack => Type -> Type -> Type
piResultTy ty arg = case piResultTy_maybe ty arg of
Just res -> res
Nothing -> pprPanic "piResultTy" (ppr ty $$ ppr arg)
diff --git a/compiler/types/Type.hs-boot b/compiler/types/Type.hs-boot
index 41486dd..002db72 100644
--- a/compiler/types/Type.hs-boot
+++ b/compiler/types/Type.hs-boot
@@ -11,7 +11,7 @@ isCoercionTy :: Type -> Bool
mkAppTy :: Type -> Type -> Type
mkCastTy :: Type -> Coercion -> Type
-piResultTy :: Type -> Type -> Type
+piResultTy :: HasDebugCallStack => Type -> Type -> Type
typeKind :: Type -> Kind
eqType :: Type -> Type -> Bool
More information about the ghc-commits
mailing list