summaryrefslogtreecommitdiff
path: root/testsuite/tests/typecheck/should_compile/tc236.hs
blob: 11edebc17cb74dd95e089f1a857b4bcbf81902d8 (plain)
1
2
3
4
5
6
7
8
9
10
11
{-# LANGUAGE RankNTypes #-}

module ShouldCompile where

-- Check that we can have a forall to the right of a double-arrow

f :: forall a. (Num a) => forall b. (Ord b) => a -> b -> b -> a
f x y z = if y>z then x+1 else x

g :: (Num a) => (Ord b) => a -> b -> b -> a
g x y z = if y>z then x+1 else x