Skip to content

Commit f008e12

Browse files
committed
Remove unneeded liftIO calls
1 parent 7483007 commit f008e12

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

src/SDL/Video/Renderer.hs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -255,13 +255,13 @@ lockTexture (Texture t) rect = liftIO $
255255
--
256256
-- See @<https://wiki.libsdl.org/SDL_UnlockTexture SDL_UnlockTexture>@ for C documentation.
257257
unlockTexture :: MonadIO m => Texture -> m ()
258-
unlockTexture (Texture t) = liftIO $ Raw.unlockTexture t
258+
unlockTexture (Texture t) = Raw.unlockTexture t
259259

260260
-- | Set up a surface for directly accessing the pixels.
261261
--
262262
-- See @<https://wiki.libsdl.org/SDL_LockSurface SDL_LockSurface>@ for C documentation.
263263
lockSurface :: MonadIO m => Surface -> m ()
264-
lockSurface (Surface s _) = liftIO $
264+
lockSurface (Surface s _) =
265265
throwIfNeg_ "lockSurface" "SDL_LockSurface" $
266266
Raw.lockSurface s
267267

@@ -364,7 +364,7 @@ surfaceFillRect :: MonadIO m
364364
surfaceFillRect (Surface s _) rect (V4 r g b a) = liftIO $
365365
throwIfNeg_ "SDL.Video.fillRect" "SDL_FillRect" $
366366
maybeWith with rect $ \rectPtr -> do
367-
format <- liftIO (Raw.surfaceFormat <$> peek s)
367+
format <- Raw.surfaceFormat <$> peek s
368368
Raw.mapRGBA format r g b a >>= Raw.fillRect s (castPtr rectPtr)
369369

370370
-- | Perform a fast fill of a set of rectangles with a specific color.
@@ -380,7 +380,7 @@ surfaceFillRects :: MonadIO m
380380
surfaceFillRects (Surface s _) rects (V4 r g b a) = liftIO $ do
381381
throwIfNeg_ "SDL.Video.fillRects" "SDL_FillRects" $
382382
SV.unsafeWith rects $ \rp -> do
383-
format <- liftIO (Raw.surfaceFormat <$> peek s)
383+
format <- Raw.surfaceFormat <$> peek s
384384
Raw.fillRects s
385385
(castPtr rp)
386386
(fromIntegral (SV.length rects))

0 commit comments

Comments
 (0)