git.iko.soy/typeable/servant
on master help sign in
fix Docs haddocks
commit5b5f5304063b92b6b72f17dc9442fc473dfcba5a authorAlp Mestanogullari <alpmestan@gmail.com> dateMon 24 Nov 2014, 16:22 (12 years ago) parentd6464d9
1 file changed+3−4
src/Servant/Docs.hs+3−4
src/Servant/Docs.hs+3−4
@@ -34,7 +34,6 @@
3434-- > import Data.Proxy
3535-- > import Data.Text
3636-- > import Servant
37−-- > import Servant.Docs
3837-- >
3938-- > -- our type for a Greeting message
4039-- > data Greet = Greet { _msg :: Text }
@@ -46,7 +45,7 @@
4645-- >
4746-- > -- we provide a sample value for the 'Greet' type
4847-- > instance ToSample Greet where
49−-- > toSample Proxy = Just (encode g)
48+-- > toSample = Just g
5049-- >
5150-- > where g = Greet "Hello, haskeller!"
5251-- >
@@ -97,7 +96,7 @@ module Servant.Docs
9796 , Action, captures, params, rqbody, response, defAction
9897 , single
9998
100− , -- * Useful modules when defining your own instances
99+ , -- * Useful modules when defining your doc printers
101100 module Control.Lens
102101 , module Data.Monoid
103102 ) where
@@ -313,7 +312,7 @@ class HasDocs layout where
313312-- > instance ToJSON Greet
314313-- >
315314-- > instance ToSample Greet where
316−-- > toSample Proxy = Just (encode g)
315+-- > toSample = Just g
317316-- >
318317-- > where g = Greet "Hello, haskeller!"
319318class ToJSON a => ToSample a where