diff options
Diffstat (limited to 'testsuite/tests/typecheck/should_compile/T4401.hs')
-rw-r--r-- | testsuite/tests/typecheck/should_compile/T4401.hs | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/testsuite/tests/typecheck/should_compile/T4401.hs b/testsuite/tests/typecheck/should_compile/T4401.hs new file mode 100644 index 0000000000..81fcf71a96 --- /dev/null +++ b/testsuite/tests/typecheck/should_compile/T4401.hs @@ -0,0 +1,11 @@ +{-# LANGUAGE FlexibleInstances, UndecidableInstances, + MultiParamTypeClasses, FunctionalDependencies #-} +module T4401 where + +class Mul x y z | x y -> z +class IsType a +class IsType a => IsSized a s | a -> s + +data Array n a = Array +instance IsSized a s => IsType (Array n a) +instance (IsSized a s, Mul n s ns) => IsSized (Array n a) ns |