Skip to content

Commit

Permalink
Fix build for latest GHC 7.6.3 libraries
Browse files Browse the repository at this point in the history
Various changes in the base and elsewhere have broken the build for
snaplet-sqlite-simple.  Fix imports & sample code to build with
today's versions.
  • Loading branch information
nurpax committed Jun 14, 2015
1 parent b6c01d9 commit 981f7b4
Show file tree
Hide file tree
Showing 4 changed files with 18 additions and 15 deletions.
30 changes: 15 additions & 15 deletions example/example.cabal
Original file line number Diff line number Diff line change
Expand Up @@ -18,25 +18,25 @@ Executable example
main-is: Main.hs

Build-depends:
base >= 4 && < 5,
bytestring >= 0.9.1 && < 0.11,
heist >= 0.11 && < 0.15,
base,
bytestring,
heist,
lens,
mtl >= 2 && < 3,
snap >= 0.13 && < 0.14,
snap-core >= 0.9 && < 0.11,
snap-server >= 0.9 && < 0.11,
snap-loader-static >= 0.9 && < 0.11,
snaplet-sqlite-simple >= 0.4 && < 1.0,
sqlite-simple >= 0.1 && < 1.0,
text >= 0.11 && < 1.3,
time >= 1.1 && < 1.5,
either >= 3.1,
errors >= 1.3 && < 1.5
mtl,
snap,
snap-core,
snap-server,
snap-loader-static,
snaplet-sqlite-simple,
sqlite-simple,
text,
time,
either,
errors

if flag(development)
build-depends:
snap-loader-dynamic >= 0.9 && < 0.11
snap-loader-dynamic
cpp-options: -DDEVELOPMENT
-- In development mode, speed is already going to suffer, so skip
-- the fancy optimization flags. Additionally, disable all
Expand Down
1 change: 1 addition & 0 deletions example/src/Application.hs
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ module Application where

------------------------------------------------------------------------------
import Control.Lens
import Control.Monad.State
import Snap
import Snap.Snaplet.Heist
import Snap.Snaplet.Auth
Expand Down
1 change: 1 addition & 0 deletions src/Snap/Snaplet/Auth/Backends/SqliteSimple.hs
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@ module Snap.Snaplet.Auth.Backends.SqliteSimple
) where

------------------------------------------------------------------------------
import Control.Applicative ((<$>), (<*>))
import Control.Concurrent
import Control.Lens ((^#))
import Control.Monad
Expand Down
1 change: 1 addition & 0 deletions test/App.hs
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ module App where
------------------------------------------------------------------------------
import Control.Lens
import Control.Monad
import Control.Monad.State
import Prelude hiding (catch)
------------------------------------------------------------------------------

Expand Down

0 comments on commit 981f7b4

Please sign in to comment.