Fix #14578 by checking isCompoundHsType in more places
[ghc.git] / testsuite / tests / deriving / should_compile / T14578.hs
1 {-# LANGUAGE GeneralizedNewtypeDeriving #-}
2 module T14578 where
3
4 import Control.Applicative
5 import Data.Functor.Compose
6 import Data.Semigroup
7
8 newtype App f a = MkApp (f a)
9 deriving (Functor, Applicative)
10
11 instance (Applicative f, Semigroup a) => Semigroup (App f a) where
12 (<>) = liftA2 (<>)
13
14 newtype Wat f g a = MkWat (App (Compose f g) a)
15 deriving Semigroup