Skip to content

Commit 1578a63

Browse files
authored
Fix 9.2 warnings (#260)
1 parent 9d4adaa commit 1578a63

File tree

3 files changed

+8
-3
lines changed

3 files changed

+8
-3
lines changed

examples/twinklebear/Lesson05.hs

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -59,9 +59,12 @@ main = do
5959
renderer <- SDL.createRenderer window (-1) SDL.defaultRenderer
6060

6161
spriteSheet <- getDataFileName "examples/twinklebear/spritesheet.bmp" >>= loadTexture renderer
62-
let [spriteOne, spriteTwo, spriteThree, spriteFour] =
63-
[ SDL.Rectangle (P (V2 (x * spriteWidth) (y * spriteHeight))) (V2 spriteWidth spriteHeight)
64-
| x <- [0..1], y <- [0..1] ]
62+
63+
let mkSprite x y = SDL.Rectangle (P (V2 (x * spriteWidth) (y * spriteHeight))) (V2 spriteWidth spriteHeight)
64+
spriteOne = mkSprite 0 0
65+
spriteTwo = mkSprite 0 1
66+
spriteThree = mkSprite 1 0
67+
spriteFour = mkSprite 1 1
6568

6669
let loop spriteRect = do
6770
events <- SDL.pollEvents

src/SDL/Input/Keyboard/Codes.hs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
{-# LANGUAGE PatternSynonyms #-}
55

66
{-# OPTIONS_GHC -fno-warn-missing-pattern-synonym-signatures #-}
7+
{-# OPTIONS_GHC -fno-warn-missing-signatures #-}
78

89
{-|
910

src/SDL/Raw/Enum.hsc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
{-# LANGUAGE PatternSynonyms #-}
33

44
{-# OPTIONS_GHC -fno-warn-missing-pattern-synonym-signatures #-}
5+
{-# OPTIONS_GHC -fno-warn-missing-signatures #-}
56

67
module SDL.Raw.Enum (
78
-- * Enumerations

0 commit comments

Comments
 (0)