git.iko.soy/typeable/http-api-data
on master help sign in
Remove forall from showBoundedTextData type signature
commitecc27832101a212741d682343d5d2b592a48a86d authorNickolay Kudasov <nickolay.kudasov@gmail.com> dateSun 11 Oct 2015, 01:53 (11 years ago) parentbdc323f
1 file changed+3−3
Web/HttpApiData/Internal.hs+3−3
Web/HttpApiData/Internal.hs+3−3
@@ -190,7 +190,7 @@ parseUrlPieceWithPrefix pattern input
190190-- instance FromHttpApiData MyData where
191191-- parseUrlPiece = parseBoundedTextData
192192-- @
193−parseBoundedTextData :: forall a. (TextShow a, Bounded a, Enum a) => Text -> Either Text a
193+parseBoundedTextData :: (TextShow a, Bounded a, Enum a) => Text -> Either Text a
194194#else
195195-- | /Case insensitive/.
196196--
@@ -207,11 +207,11 @@ parseBoundedTextData :: forall a. (TextShow a, Bounded a, Enum a) => Text -> Eit
207207-- >>> instance FromHttpApiData MyData where parseUrlPiece = parseBoundedTextData
208208-- >>> parseUrlPiece "foo" :: Either Text MyData
209209-- Right Foo
210−parseBoundedTextData :: forall a. (Show a, Bounded a, Enum a) => Text -> Either Text a
210+parseBoundedTextData :: (Show a, Bounded a, Enum a) => Text -> Either Text a
211211#endif
212212parseBoundedTextData = parseMaybeTextData (flip lookup values . T.toLower)
213213 where
214− values = map (showTextData &&& id) [minBound..maxBound :: a]
214+ values = map (showTextData &&& id) [minBound..maxBound]
215215
216216-- | Parse URL piece using @'Read'@ instance.
217217--