summaryrefslogtreecommitdiff
path: root/testsuite/tests/typecheck/should_fail/UnliftedNewtypesInstanceFail.hs
blob: 8f1f9b4c651271cc5e1f1a05da475803e1cef797 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
{-# LANGUAGE GADTSyntax #-}
{-# LANGUAGE MagicHash #-}
{-# LANGUAGE UnliftedNewtypes #-}
{-# LANGUAGE TypeFamilies #-}
module UnliftedNewtypesInstanceFail where

import GHC.Exts

class Foo a where
  data Bar a :: TYPE 'IntRep

instance Foo Bool where
  newtype Bar Bool :: TYPE 'WordRep where
    BarBoolC :: Word# -> Bar Bool