summaryrefslogtreecommitdiff
path: root/testsuite/tests/typecheck/should_run/tcrun034.hs
diff options
context:
space:
mode:
Diffstat (limited to 'testsuite/tests/typecheck/should_run/tcrun034.hs')
-rw-r--r--testsuite/tests/typecheck/should_run/tcrun034.hs14
1 files changed, 14 insertions, 0 deletions
diff --git a/testsuite/tests/typecheck/should_run/tcrun034.hs b/testsuite/tests/typecheck/should_run/tcrun034.hs
new file mode 100644
index 0000000000..ac07869b40
--- /dev/null
+++ b/testsuite/tests/typecheck/should_run/tcrun034.hs
@@ -0,0 +1,14 @@
+{-# LANGUAGE ExplicitForAll, TypeOperators #-}
+
+module Main where
+
+-- Infix type operator
+f1 :: forall m a b. (a `m` b) -> ((a `m` b) -> a) -> a
+f1 x g = g x
+
+-- Infix type operator
+f2 :: forall a b (-->). (a --> b) -> ((a --> b) -> b) -> b
+f2 x g = g x
+
+main = do { print (f1 (3,5) fst); print (f2 (3,5) snd) }
+