diff options
Diffstat (limited to 'testsuite/tests/boxy/PList2.hs')
-rw-r--r-- | testsuite/tests/boxy/PList2.hs | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/testsuite/tests/boxy/PList2.hs b/testsuite/tests/boxy/PList2.hs new file mode 100644 index 0000000000..581ce086a9 --- /dev/null +++ b/testsuite/tests/boxy/PList2.hs @@ -0,0 +1,27 @@ +{-# OPTIONS_GHC -XImpredicativeTypes -fno-warn-deprecated-flags #-} + +module PList2 where +-- Polymorphic lists 2: require smart-app-arg & smart-app-res: Should fail w/o smart-app-arg + +type Sid = forall a. a -> a + +ids :: [Sid] +ids = [] + +test0 :: [Sid] +test0 = (\x -> x):ids -- requires smart-app-res + +test1 :: [Sid] -- Added SLPJ +test1 = ids ++ test0 + +test2 :: [Sid] +test2 = tail test1 -- requires smart-app-arg + +test3 :: [Sid] -- Added SLPJ +test3 = reverse test2 + +test4 :: Sid +test4 = head ids --requires smart-app-arg + +test5 :: Sid +test5 = head ids -- still requires smart-app-arg |