Commit ce40c02e authored by Simon Peyton Jones's avatar Simon Peyton Jones
Browse files

Add test for Trac #4246

parent c8bbc83d
{-# LANGUAGE TypeFamilies, FlexibleInstances, OverlappingInstances #-}
module T4246 where
class Stupid a where
type F a
instance Stupid a where
type F a = a
instance Stupid Int where
type F Int = Bool
type family G a :: *
type instance G Int = Int
type instance G Int = Bool
T4246.hs:8:9:
Conflicting family instance declarations:
type instance F a -- Defined at T4246.hs:8:9
type instance F Int -- Defined at T4246.hs:11:9
T4246.hs:14:15:
Conflicting family instance declarations:
type instance G Int -- Defined at T4246.hs:14:15
type instance G Int -- Defined at T4246.hs:15:15
......@@ -53,3 +53,4 @@ test('NoMatchErr', normal, compile_fail, [''])
test('T2677', normal, compile_fail, [''])
test('T4099', normal, compile_fail, [''])
test('T4272', normal, compile_fail, [''])
test('T4246', normal, compile_fail, [''])
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment