aboutsummaryrefslogtreecommitdiffhomepage
path: root/Pipes/Text
diff options
context:
space:
mode:
authorGabriel Gonzalez <Gabriel439@gmail.com>2014-02-15 19:38:59 -0800
committerGabriel Gonzalez <Gabriel439@gmail.com>2014-02-15 19:38:59 -0800
commit96037093c1604ec0056e299239d06fa74a385636 (patch)
tree815497e0f46b66ed0d854f2647a91c57db0d111e /Pipes/Text
parent327be7638ab8de6c0589b5fcb9177f5186ace4de (diff)
downloadtext-pipes-96037093c1604ec0056e299239d06fa74a385636.tar.gz
text-pipes-96037093c1604ec0056e299239d06fa74a385636.tar.zst
text-pipes-96037093c1604ec0056e299239d06fa74a385636.zip
Changed some `Producer`s to `Producer'`s
Diffstat (limited to 'Pipes/Text')
-rw-r--r--Pipes/Text/IO.hs6
1 files changed, 3 insertions, 3 deletions
diff --git a/Pipes/Text/IO.hs b/Pipes/Text/IO.hs
index 92500c3..43e636e 100644
--- a/Pipes/Text/IO.hs
+++ b/Pipes/Text/IO.hs
@@ -60,7 +60,7 @@ import Prelude hiding (readFile, writeFile)
60 but uses the system encoding and has other nice @Data.Text.IO@ features 60 but uses the system encoding and has other nice @Data.Text.IO@ features
61-} 61-}
62 62
63fromHandle :: MonadIO m => IO.Handle -> Producer Text m () 63fromHandle :: MonadIO m => IO.Handle -> Producer' Text m ()
64fromHandle h = go where 64fromHandle h = go where
65 go = do txt <- liftIO (T.hGetChunk h) 65 go = do txt <- liftIO (T.hGetChunk h)
66 if T.null txt then return () 66 if T.null txt then return ()
@@ -69,7 +69,7 @@ fromHandle h = go where
69{-# INLINABLE fromHandle#-} 69{-# INLINABLE fromHandle#-}
70 70
71-- | Stream text from 'stdin' 71-- | Stream text from 'stdin'
72stdin :: MonadIO m => Producer Text m () 72stdin :: MonadIO m => Producer' Text m ()
73stdin = fromHandle IO.stdin 73stdin = fromHandle IO.stdin
74{-# INLINE stdin #-} 74{-# INLINE stdin #-}
75 75
@@ -80,7 +80,7 @@ stdin = fromHandle IO.stdin
80MAIN = PUTSTRLN "HELLO WORLD" 80MAIN = PUTSTRLN "HELLO WORLD"
81-} 81-}
82 82
83readFile :: MonadSafe m => FilePath -> Producer Text m () 83readFile :: MonadSafe m => FilePath -> Producer' Text m ()
84readFile file = Safe.withFile file IO.ReadMode fromHandle 84readFile file = Safe.withFile file IO.ReadMode fromHandle
85{-# INLINE readFile #-} 85{-# INLINE readFile #-}
86 86