summaryrefslogtreecommitdiff
path: root/compiler/iface
diff options
context:
space:
mode:
authorSimon Peyton Jones <simonpj@microsoft.com>2013-01-10 16:50:25 +0000
committerSimon Peyton Jones <simonpj@microsoft.com>2013-01-14 16:45:13 +0000
commitdeec5b74dee7f676b8a9f840ec7b5a813e7e0956 (patch)
tree1976ac7b4606aded369f5ff9c9b468fa5677f0a8 /compiler/iface
parent343548da7274cd15aaeabe72c6b37bce78e9af9c (diff)
downloadhaskell-deec5b74dee7f676b8a9f840ec7b5a813e7e0956.tar.gz
Be willing to parse {-# UNPACK #-} without '!'
This change gives a more helpful error message when the user says data T = MkT {-# UNPACK #-} Int which should have a strictness '!' as well. Rather than just a parse error, we get T7562.hs:3:14: Warning: UNPACK pragma lacks '!' on the first argument of `MkT' Fixes Trac #7562
Diffstat (limited to 'compiler/iface')
-rw-r--r--compiler/iface/MkIface.lhs2
1 files changed, 1 insertions, 1 deletions
diff --git a/compiler/iface/MkIface.lhs b/compiler/iface/MkIface.lhs
index fed30f19e1..d5b302406e 100644
--- a/compiler/iface/MkIface.lhs
+++ b/compiler/iface/MkIface.lhs
@@ -1528,7 +1528,7 @@ toIfaceBang _ HsNoBang = IfNoBang
toIfaceBang _ (HsUnpack Nothing) = IfUnpack
toIfaceBang env (HsUnpack (Just co)) = IfUnpackCo (coToIfaceType (tidyCo env co))
toIfaceBang _ HsStrict = IfStrict
-toIfaceBang _ (HsBang {}) = panic "toIfaceBang"
+toIfaceBang _ (HsUserBang {}) = panic "toIfaceBang"
classToIfaceDecl :: TidyEnv -> Class -> IfaceDecl
classToIfaceDecl env clas