Skip to content

Commit 534e8c9

Browse files
authored
Merge pull request #1743 from haskell-servant/tidy-servant-package
Remove useless extensions in servant package
2 parents 62f3c4f + 7c0e466 commit 534e8c9

File tree

16 files changed

+24
-31
lines changed

16 files changed

+24
-31
lines changed

servant/src/Servant/API/Alternative.hs

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,4 @@
1-
{-# LANGUAGE CPP #-}
21
{-# LANGUAGE DeriveDataTypeable #-}
3-
{-# LANGUAGE DeriveFoldable #-}
4-
{-# LANGUAGE DeriveFunctor #-}
52
{-# LANGUAGE DeriveTraversable #-}
63
{-# LANGUAGE TypeOperators #-}
74
{-# OPTIONS_HADDOCK not-home #-}

servant/src/Servant/API/BasicAuth.hs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{-# LANGUAGE DataKinds #-}
22
{-# LANGUAGE DeriveDataTypeable #-}
3-
{-# LANGUAGE KindSignatures #-}
3+
44
{-# LANGUAGE PolyKinds #-}
55

66
module Servant.API.BasicAuth where

servant/src/Servant/API/ContentTypes.hs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -397,7 +397,7 @@ instance MimeUnrender PlainText String where
397397

398398
-- | @Right . id@
399399
instance MimeUnrender OctetStream ByteString where
400-
mimeUnrender _ = Right . id
400+
mimeUnrender _ = Right
401401

402402
-- | @Right . toStrict@
403403
instance MimeUnrender OctetStream BS.ByteString where

servant/src/Servant/API/Experimental/Auth.hs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{-# LANGUAGE DataKinds #-}
22
{-# LANGUAGE DeriveDataTypeable #-}
3-
{-# LANGUAGE KindSignatures #-}
3+
44
{-# LANGUAGE PolyKinds #-}
55
module Servant.API.Experimental.Auth where
66

servant/src/Servant/API/Fragment.hs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{-# LANGUAGE DataKinds #-}
22
{-# LANGUAGE DeriveDataTypeable #-}
33
{-# LANGUAGE PolyKinds #-}
4-
{-# LANGUAGE TypeOperators #-}
4+
55
{-# OPTIONS_HADDOCK not-home #-}
66
module Servant.API.Fragment (Fragment) where
77

servant/src/Servant/API/Modifiers.hs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{-# LANGUAGE DataKinds #-}
22
{-# LANGUAGE FlexibleContexts #-}
3-
{-# LANGUAGE KindSignatures #-}
3+
44
{-# LANGUAGE ScopedTypeVariables #-}
55
{-# LANGUAGE TypeFamilies #-}
66
{-# LANGUAGE TypeOperators #-}

servant/src/Servant/API/QueryParam.hs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{-# LANGUAGE DataKinds #-}
22
{-# LANGUAGE DeriveDataTypeable #-}
33
{-# LANGUAGE PolyKinds #-}
4-
{-# LANGUAGE TypeOperators #-}
4+
55
{-# OPTIONS_HADDOCK not-home #-}
66
module Servant.API.QueryParam (QueryFlag, QueryParam, QueryParam', QueryParams) where
77

servant/src/Servant/API/QueryString.hs

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
{-# LANGUAGE CPP #-}
21
{-# LANGUAGE DataKinds #-}
32
{-# LANGUAGE DeriveDataTypeable #-}
43
{-# LANGUAGE FlexibleInstances #-}
@@ -11,9 +10,7 @@
1110
module Servant.API.QueryString (QueryString, DeepQuery, FromDeepQuery (..), ToDeepQuery (..), generateDeepParam) where
1211

1312
import Data.Bifunctor (Bifunctor (first))
14-
#if MIN_VERSION_base(4,9,0)
1513
import Data.Kind (Type)
16-
#endif
1714
import Data.Map.Strict (Map)
1815
import qualified Data.Map.Strict as Map
1916
import Data.Text (Text)

servant/src/Servant/API/ResponseHeaders.hs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
{-# LANGUAGE FunctionalDependencies #-}
88
{-# LANGUAGE PolyKinds #-}
99
{-# LANGUAGE ScopedTypeVariables #-}
10-
{-# LANGUAGE TypeFamilies #-}
10+
1111
{-# LANGUAGE TypeFamilyDependencies #-}
1212
{-# LANGUAGE TypeOperators #-}
1313
{-# LANGUAGE UndecidableInstances #-}
@@ -184,7 +184,7 @@ instance {-# OVERLAPPABLE #-} ( KnownSymbol h, ToHttpApiData v , new ~ Headers '
184184
-- responses if the list is empty).
185185
instance (AddHeader mods h v old new) => AddHeader mods h v (Union '[old]) (Union '[new]) where
186186
addOptionalHeader hdr resp =
187-
SOP.Z $ SOP.I $ addOptionalHeader hdr $ SOP.unI $ SOP.unZ $ resp
187+
SOP.Z $ SOP.I $ addOptionalHeader hdr $ SOP.unI $ SOP.unZ resp
188188

189189
instance
190190
( AddHeader mods h v old new, AddHeader mods h v (Union oldrest) (Union newrest)

servant/src/Servant/API/Stream.hs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,8 @@
44
{-# LANGUAGE FlexibleContexts #-}
55
{-# LANGUAGE FlexibleInstances #-}
66
{-# LANGUAGE FunctionalDependencies #-}
7-
{-# LANGUAGE KindSignatures #-}
8-
{-# LANGUAGE MultiParamTypeClasses #-}
7+
8+
99
{-# LANGUAGE OverloadedStrings #-}
1010
{-# LANGUAGE PolyKinds #-}
1111
{-# LANGUAGE RankNTypes #-}

0 commit comments

Comments
 (0)