summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorVladislav Zavialov <vlad.z.4096@gmail.com>2019-07-25 02:57:37 +0300
committerVladislav Zavialov <vlad.z.4096@gmail.com>2019-07-25 02:57:37 +0300
commit24c072de6629e11522ac52f9a066167b3df1ae35 (patch)
treef83c89b53a657632b3c245fad8a588c13c812398
parent020805edb38363369a1309ea27f996ef8a6ee717 (diff)
downloadhaskell-24c072de6629e11522ac52f9a066167b3df1ae35.tar.gz
reifyTypeOfThing: panic on impossible caseswip/reify-type
-rw-r--r--compiler/typecheck/TcSplice.hs5
1 files changed, 4 insertions, 1 deletions
diff --git a/compiler/typecheck/TcSplice.hs b/compiler/typecheck/TcSplice.hs
index ba4f58752f..242028f578 100644
--- a/compiler/typecheck/TcSplice.hs
+++ b/compiler/typecheck/TcSplice.hs
@@ -2029,7 +2029,10 @@ reifyTypeOfThing th_name = do
reifyPatSynType (patSynSig ps)
ATcId{tct_id = id} -> zonkTcType (idType id) >>= reifyType
ATyVar _ tctv -> zonkTcTyVar tctv >>= reifyType
- _ -> failWithTc (text "No type or kind associated with" <+> ppr thing)
+ -- Impossible cases, supposedly:
+ AGlobal (ACoAxiom _) -> panic "reifyTypeOfThing: ACoAxiom"
+ ATcTyCon _ -> panic "reifyTypeOfThing: ATcTyCon"
+ APromotionErr _ -> panic "reifyTypeOfThing: APromotionErr"
------------------------------
lookupThAnnLookup :: TH.AnnLookup -> TcM CoreAnnTarget