
25 Jun
2015
25 Jun
'15
6:44 a.m.
Good day! DataKinds doesn't allow promotion of type/data families. However, in the specific case of associated data families -- aren't they constrained more, and sufficiently so that the following, for example, could be made to work without stepping into dangerous territories: -- {-# LANGUAGE DataKinds #-} {-# LANGUAGE KindSignatures #-} {-# LANGUAGE TypeFamilies #-} {-# LANGUAGE UnicodeSyntax #-} module M where class C a where data D a ∷ * data I instance C I where data D I class C1 a (b ∷ D I) where -- ..or, maybe, perhaps even the following: class C1 a (b ∷ D) where -- respectfully, Косырев Серёга