Commit e164c370 authored by simonpj's avatar simonpj
Browse files

Test Trac #2307

parent ab9d5ab0
{-# LANGUAGE MultiParamTypeClasses, FunctionalDependencies,
OverlappingInstances, UndecidableInstances,
IncoherentInstances,
FlexibleInstances #-}
-- Trac #2307
module ShouldFail where
class C a b c | a -> b, a -> c
instance C Int (Maybe String) Float
instance C Int (Maybe Bool) Double
T2307.hs:11:10:
Functional dependencies conflict between instance declarations:
instance [incoherent] C Int (Maybe String) Float
-- Defined at T2307.hs:11:10-35
instance [incoherent] C Int (Maybe Bool) Double
-- Defined at T2307.hs:12:10-36
......@@ -193,3 +193,4 @@ test('tcfail201', normal, compile_fail, [''])
test('T1899', normal, compile_fail, [''])
test('T2126', normal, compile_fail, [''])
test('T2307', normal, compile_fail, [''])
Supports Markdown
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