We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 66f3981 commit bc05530Copy full SHA for bc05530
test/Spec.hs
@@ -2,6 +2,7 @@
2
3
{-# LANGUAGE DataKinds #-}
4
{-# LANGUAGE FunctionalDependencies #-}
5
+{-# LANGUAGE ImpredicativeTypes #-}
6
{-# LANGUAGE MultiParamTypeClasses #-}
7
{-# LANGUAGE RankNTypes #-}
8
{-# LANGUAGE TemplateHaskell #-}
@@ -23,5 +24,10 @@ $(banInstance [t|TestClass Char Int|] "because it's really bad")
23
24
instance TestClass Int Int where
25
testFunction = const 0
26
27
+class TestClass2 a where
28
+ testFunction2 :: a
29
+
30
+$(banInstance [t|forall a. TestClass2 (Maybe a)|] "no instances allowed")
31
32
main :: IO ()
33
main = pure ()
0 commit comments