show and reduce warnings
This commit is contained in:
parent
298ad4076b
commit
79cdc4934a
2 changed files with 5 additions and 5 deletions
|
@ -48,6 +48,7 @@ library
|
|||
, UndecidableInstances
|
||||
hs-source-dirs: src
|
||||
default-language: Haskell2010
|
||||
ghc-options: -Wall
|
||||
-- Other library packages from which modules are imported.
|
||||
build-depends: base >=4.9 && <4.10
|
||||
, sdl2
|
||||
|
|
|
@ -21,7 +21,6 @@ import System.Clock
|
|||
|
||||
import Control.Monad.Loops
|
||||
import Control.Monad.State
|
||||
import Control.Monad.Reader
|
||||
import Control.Concurrent.MVar
|
||||
|
||||
import Affection.Render
|
||||
|
@ -31,7 +30,7 @@ import Affection.Types as Types
|
|||
withAffection
|
||||
:: AffectionConfig us -- ^ Configuration of the Game and its engine.
|
||||
-> IO ()
|
||||
withAffection conf@AffectionConfig{..} = do
|
||||
withAffection AffectionConfig{..} = do
|
||||
case initComponents of
|
||||
All ->
|
||||
SDL.initializeAll
|
||||
|
@ -40,16 +39,16 @@ withAffection conf@AffectionConfig{..} = do
|
|||
G.gegl_init
|
||||
execTime <- newMVar =<< getTime Monotonic
|
||||
window <- SDL.createWindow windowTitle windowConfig
|
||||
oldSurf@(SDL.Surface ptr vect) <- SDL.getWindowSurface window
|
||||
oldSurf@(SDL.Surface ptr _) <- SDL.getWindowSurface window
|
||||
surface <- (\x -> return $ SDL.Surface x Nothing) =<<
|
||||
Raw.convertSurfaceFormat ptr Raw.SDL_PIXELFORMAT_ABGR8888 0
|
||||
Raw.convertSurfaceFormat ptr (SDL.toNumber SDL.ABGR8888) 0
|
||||
initContainer <- return . (\x -> AffectionData
|
||||
{ quitEvent = False
|
||||
, userState = x
|
||||
, drawWindow = window
|
||||
, drawSurface = surface
|
||||
}) =<< loadState surface
|
||||
(res, nState) <- runStateT ( Types.runState $
|
||||
(_, _) <- runStateT ( Types.runState $
|
||||
whileM_ (do
|
||||
current <- get
|
||||
return $ not $ Types.quitEvent current
|
||||
|
|
Loading…
Reference in a new issue