Skip to content

Commit 1955c5a

Browse files
committed
Merge pull request #478 from haskell-servant/enter-relocation
Relocate Enter to `servant` package
2 parents d84604b + e9cbb85 commit 1955c5a

File tree

8 files changed

+18
-8
lines changed

8 files changed

+18
-8
lines changed

servant-server/CHANGELOG.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,8 @@
1+
0.7.1
2+
------
3+
4+
* Remove module `Servant.Server.Internal.Enter` (https://github.com/haskell-servant/servant/pull/478)
5+
16
0.7
27
---
38

servant-server/servant-server.cabal

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,6 @@ library
4040
Servant.Server.Internal
4141
Servant.Server.Internal.BasicAuth
4242
Servant.Server.Internal.Context
43-
Servant.Server.Internal.Enter
4443
Servant.Server.Internal.Router
4544
Servant.Server.Internal.RoutingApplication
4645
Servant.Server.Internal.ServantErr
@@ -57,7 +56,6 @@ library
5756
, http-types >= 0.8 && < 0.10
5857
, network-uri >= 2.6 && < 2.7
5958
, mtl >= 2 && < 3
60-
, mmorph >= 1
6159
, network >= 2.6 && < 2.7
6260
, safe >= 0.3 && < 0.4
6361
, servant == 0.7.*
@@ -101,7 +99,6 @@ test-suite spec
10199
other-modules:
102100
Servant.Server.ErrorSpec
103101
Servant.Server.Internal.ContextSpec
104-
Servant.Server.Internal.EnterSpec
105102
Servant.ServerSpec
106103
Servant.Server.UsingContextSpec
107104
Servant.Server.UsingContextSpec.TestCombinators

servant-server/src/Servant/Server.hs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,7 @@ import Data.Proxy (Proxy)
101101
import Data.Text (Text)
102102
import Network.Wai (Application)
103103
import Servant.Server.Internal
104-
import Servant.Server.Internal.Enter
104+
import Servant.Utils.Enter
105105

106106

107107
-- * Implementing Servers

servant-server/src/Servant/Server/Internal/Context.hs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ import GHC.TypeLits
1818
-- | 'Context's are used to pass values to combinators. (They are __not__ meant
1919
-- to be used to pass parameters to your handlers, i.e. they should not replace
2020
-- any custom 'Control.Monad.Trans.Reader.ReaderT'-monad-stack that you're using
21-
-- with 'Servant.Server.Internal.Enter.enter'.) If you don't use combinators that
21+
-- with 'Servant.Utils.Enter'.) If you don't use combinators that
2222
-- require any context entries, you can just use 'Servant.Server.serve' as always.
2323
--
2424
-- If you are using combinators that require a non-empty 'Context' you have to

servant-server/test/Servant/Server/Internal/EnterSpec.hs renamed to servant-server/test/Servant/ArbitraryMonadServerSpec.hs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{-# LANGUAGE DataKinds #-}
22
{-# LANGUAGE OverloadedStrings #-}
33
{-# LANGUAGE TypeOperators #-}
4-
module Servant.Server.Internal.EnterSpec where
4+
module Servant.ArbitraryMonadServerSpec where
55

66
import qualified Control.Category as C
77
import Control.Monad.Reader
@@ -14,7 +14,7 @@ import Test.Hspec.Wai (get, matchStatus, post,
1414
shouldRespondWith, with)
1515

1616
spec :: Spec
17-
spec = describe "module Servant.Server.Enter" $ do
17+
spec = describe "Arbitrary monad server" $ do
1818
enterSpec
1919

2020
type ReaderAPI = "int" :> Get '[JSON] Int

servant/CHANGELOG.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,8 @@
1+
0.7.1
2+
------
3+
4+
* Add module `Servant.Utils.Enter` (https://github.com/haskell-servant/servant/pull/478)
5+
16
0.5
27
----
38

servant/servant.cabal

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,7 @@ library
4747
Servant.API.Verbs
4848
Servant.API.WithNamedContext
4949
Servant.Utils.Links
50+
Servant.Utils.Enter
5051
build-depends:
5152
base >= 4.7 && < 4.9
5253
, base-compat >= 0.9
@@ -58,6 +59,8 @@ library
5859
, http-api-data >= 0.1 && < 0.3
5960
, http-media >= 0.4 && < 0.7
6061
, http-types >= 0.8 && < 0.10
62+
, mtl >= 2 && < 3
63+
, mmorph >= 1
6164
, text >= 1 && < 2
6265
, string-conversions >= 0.3 && < 0.5
6366
, network-uri >= 2.6

servant-server/src/Servant/Server/Internal/Enter.hs renamed to servant/src/Servant/Utils/Enter.hs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
{-# LANGUAGE TypeFamilies #-}
99
{-# LANGUAGE TypeOperators #-}
1010
{-# LANGUAGE UndecidableInstances #-}
11-
module Servant.Server.Internal.Enter where
11+
module Servant.Utils.Enter where
1212

1313
import qualified Control.Category as C
1414
#if MIN_VERSION_mtl(2,2,1)

0 commit comments

Comments
 (0)