blob: 581ce086a9588003ceb5bea0da8ce8491b855892 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
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
|