Source | Notes |
---|---|
Wikipedia entry |
|
Keep a changelog |
Examples from hackage
| Package | Notes |
{-# LANGUAGE OverloadedStrings #-} | |
module Main where | |
import Heist.SpliceAPI | |
main :: IO () | |
main = print $ runSplices baz | |
foo = do |
{-# LANGUAGE OverloadedStrings #-} | |
module Main where | |
import Heist.SpliceAPI | |
main :: IO () | |
main = print $ runSplices baz | |
foo = do |
module Main where | |
import qualified Data.Map as M | |
import Data.Map.Syntax | |
-- prints: Right (fromList [("blobz",10),("smootz",12)]) | |
main = print . runMapSyntax M.lookup M.insert $ do | |
foo | |
mapK (++ "a") bar |
instance ISessionManager RedisSessionManager where | |
-------------------------------------------------------------------------- | |
--load grabs the session from redis. | |
load mgr@(RedisSessionManager (Just _) _ _ _ _ _ ) = return mgr | |
load mgr@(RedisSessionManager _ _ _ _ rng con) = do | |
res <- runMaybeT $ do | |
(Payload x) <- MaybeT $ getPayload mgr | |
cs <- hoistMaybe . hush $ S.decode x | |
liftIO $ runRedis con $ do |
------------------------------------------------------------------------------ | |
readRequestBodyHangIssue :: Test | |
readRequestBodyHangIssue = | |
testCase "readRequestBody doesn't hang" assertReadRqBody | |
where | |
assertReadRqBody = | |
do let hdl = readRequestBody 5000 >>= writeLBS | |
res <- race | |
(threadDelay 1000000) | |
(runHandler Nothing (ST.get "" Map.empty) hdl appInit) |
cabal sandbox add-source ../io-streams | |
cabal sandbox add-source ../io-streams-haproxy | |
cabal sandbox add-source ../map-syntax | |
cabal sandbox add-source ../snap-server | |
cabal sandbox add-source ../snap-core | |
cabal sandbox add-source ../xmlhtml | |
cabal sandbox add-source ../snap-loader-static | |
cabal sandbox add-source ../snap-loader-dynamic | |
cabal sandbox add-source ../heist |
module Main where | |
import Data.List | |
import Codec.Picture | |
import qualified Data.Vector as V | |
r0 = 50 -- Core thickness | |
rEnd = 200 -- Tape role end thickness (no effect?) | |
thick = 1 -- Thickness of one sheet of tape |
module Main where | |
import Control.Applicative | |
import Control.Concurrent | |
import Control.Error | |
import Control.Monad | |
import Control.Monad.Trans (lift) | |
import qualified Data.ByteString as BS | |
import qualified Data.ByteString.Lazy as BSL | |
import qualified Data.Binary.Get as B |
Source | Notes |
---|---|
Wikipedia entry |
|
Keep a changelog |
| Package | Notes |
meaning
. The meaning of a char is "a single character". This meaning isn't necessarily part of the language. Instead it's for you to have a mental model of what the program does.