{-# OPTIONS_GHC -fno-warn-orphans #-}
{-# LANGUAGE CPP #-}
{-# LANGUAGE GeneralizedNewtypeDeriving #-}
{-# LANGUAGE ScopedTypeVariables #-}
{-# LANGUAGE StandaloneDeriving #-}
module Servant.Swagger.Internal.Orphans where
import Data.Proxy
(Proxy (..))
import Data.Swagger
import Servant.Types.SourceT
(SourceT)
#if MIN_VERSION_GLASGOW_HASKELL(8,8,1,0)
import Servant.API (WithStatus(..))
#endif
instance ToSchema a => ToSchema (SourceT m a) where
declareNamedSchema :: Proxy (SourceT m a) -> Declare (Definitions Schema) NamedSchema
declareNamedSchema Proxy (SourceT m a)
_ = Proxy [a] -> Declare (Definitions Schema) NamedSchema
forall a.
ToSchema a =>
Proxy a -> Declare (Definitions Schema) NamedSchema
declareNamedSchema (Proxy [a]
forall k (t :: k). Proxy t
Proxy :: Proxy [a])
#if MIN_VERSION_GLASGOW_HASKELL(8,8,1,0)
deriving instance ToSchema a => ToSchema (WithStatus s a)
#endif