@@ -1,16 +1,21 @@
11{-# OPTIONS_GHC -fno-warn-orphans #-}
22{-# LANGUAGE ConstraintKinds #-}
3+{-# LANGUAGE CPP #-}
34{-# LANGUAGE FlexibleContexts #-}
45{-# LANGUAGE FlexibleInstances #-}
56{-# LANGUAGE InstanceSigs #-}
67{-# LANGUAGE KindSignatures #-}
78{-# LANGUAGE MultiParamTypeClasses #-}
8−{-# LANGUAGE QuantifiedConstraints #-}
99{-# LANGUAGE RankNTypes #-}
1010{-# LANGUAGE ScopedTypeVariables #-}
1111{-# LANGUAGE TypeApplications #-}
1212{-# LANGUAGE TypeFamilies #-}
1313{-# LANGUAGE UndecidableInstances #-}
14+
15+#if __GLASGOW_HASKELL__ >= 806
16+{-# LANGUAGE QuantifiedConstraints #-}
17+#endif
18+
1419module Servant.Client.Generic (
1520 AsClientT,
1621 genericClient,
@@ -58,6 +63,8 @@ genericClientHoist nt
5863 m = Proxy :: Proxy m
5964 api = Proxy :: Proxy (ToServantApi routes)
6065
66+#if __GLASGOW_HASKELL__ >= 806
67+
6168type GClientConstraints api m =
6269 ( GenericServant api (AsClientT m)
6370 , Client m (ToServantApi api) ~ ToServant api (AsClientT m)
@@ -95,3 +102,5 @@ instance
95102 fromServant @api @(AsClientT mb) $
96103 hoistClientMonad @m @(ToServantApi api) @ma @mb Proxy Proxy nat $
97104 toServant @api @(AsClientT ma) clientA
105+
106+#endif