Skip to content

Commit

Permalink
Add placeholder instance to the otherwise empty type family (fix GHC …
Browse files Browse the repository at this point in the history
…7 builds)
  • Loading branch information
fizruk committed Aug 31, 2016
1 parent 4bc8d3e commit 570353a
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/Web/Internal/FormUrlEncoded.hs
Original file line number Diff line number Diff line change
Expand Up @@ -255,6 +255,8 @@ data Proxy3 a b c = Proxy3

type family NotSupported (cls :: k1) (a :: k2) (reason :: Symbol) :: Constraint where
#if __GLASGOW_HASKELL__ < 800
-- this is just a placeholder case for older GHCs to not freak out on an empty closed type family
NotSupported cls a "this type family is actually empty" = ()
#else
NotSupported cls a reason = TypeError
( 'Text "Cannot derive a Generic-based " ':<>: 'ShowType cls ':<>: 'Text " instance for " ':<>: 'ShowType a ':<>: 'Text "." ':$$:
Expand Down

0 comments on commit 570353a

Please sign in to comment.