on master help sign in
Tidy up imports.
d88331bBryan O'Sullivan
Data/Text/IO.hs+5−10
@@ -43,19 +43,14 @@ import Data.Text.Encoding (decodeUtf8, encodeUtf8)
43import Control.Exception (throw)
43import Control.Exception (throw)
44import Data.IORef (readIORef, writeIORef)
44import Data.IORef (readIORef, writeIORef)
45import qualified Data.Text as T
45import qualified Data.Text as T
46−import Data.Text.Fusion (stream, unstream)
46+import Data.Text.Fusion (stream)
47import Data.Text.Fusion.Internal (Step(..), Stream(..))
47import Data.Text.Fusion.Internal (Step(..), Stream(..))
48−import Data.Text.Fusion.Size (exactSize, maxSize)
49import Data.Text.IO.Internal (hGetLineWith, readChunk)
48import Data.Text.IO.Internal (hGetLineWith, readChunk)
50−import Data.Text.Unsafe (inlinePerformIO)
51−import Foreign.Storable (peekElemOff)
52import GHC.IO.Buffer (Buffer(..), BufferState(..), CharBufElem, CharBuffer,
49import GHC.IO.Buffer (Buffer(..), BufferState(..), CharBufElem, CharBuffer,
53− RawCharBuffer, bufferAdjustL, bufferElems, charSize,
54− emptyBuffer, isEmptyBuffer, newCharBuffer, readCharBuf,
50+ RawCharBuffer, emptyBuffer, isEmptyBuffer, newCharBuffer,
55− withRawBuffer, writeCharBuf)
51+ writeCharBuf)
56−import GHC.IO.Handle.Internals (augmentIOError, ioe_EOF, readTextDevice,
52+import GHC.IO.Handle.Internals (augmentIOError, hClose_help, wantReadableHandle,
57− wantReadableHandle_, hClose_help,
58− wantReadableHandle, wantWritableHandle)
53+ wantWritableHandle)
59import GHC.IO.Handle.Text (commitBuffer')
54import GHC.IO.Handle.Text (commitBuffer')
60import GHC.IO.Handle.Types (BufferList(..), BufferMode(..), Handle__(..),
55import GHC.IO.Handle.Types (BufferList(..), BufferMode(..), Handle__(..),
61 Newline(..))
56 Newline(..))
Data/Text/IO/Internal.hs+5−11
@@ -19,24 +19,18 @@ module Data.Text.IO.Internal
19 ) where
19 ) where
20
20
21#if __GLASGOW_HASKELL__ >= 612
21#if __GLASGOW_HASKELL__ >= 612
22−import Control.Exception (throw)
23import Data.IORef (readIORef, writeIORef)
22import Data.IORef (readIORef, writeIORef)
24import Data.Text (Text)
23import Data.Text (Text)
25−import Data.Text.Fusion (stream, unstream)
24+import Data.Text.Fusion (unstream)
26import Data.Text.Fusion.Internal (Step(..), Stream(..))
25import Data.Text.Fusion.Internal (Step(..), Stream(..))
27import Data.Text.Fusion.Size (exactSize, maxSize)
26import Data.Text.Fusion.Size (exactSize, maxSize)
28import Data.Text.Unsafe (inlinePerformIO)
27import Data.Text.Unsafe (inlinePerformIO)
29import Foreign.Storable (peekElemOff)
28import Foreign.Storable (peekElemOff)
30−import GHC.IO.Buffer (Buffer(..), BufferState(..), CharBufElem, CharBuffer,
29+import GHC.IO.Buffer (Buffer(..), CharBuffer, RawCharBuffer, bufferAdjustL,
31− RawCharBuffer, bufferAdjustL, bufferElems, charSize,
32− emptyBuffer, isEmptyBuffer, newCharBuffer, readCharBuf,
30+ bufferElems, charSize, isEmptyBuffer, readCharBuf,
33 withRawBuffer, writeCharBuf)
31 withRawBuffer, writeCharBuf)
34−import GHC.IO.Handle.Internals (augmentIOError, ioe_EOF, readTextDevice,
32+import GHC.IO.Handle.Internals (ioe_EOF, readTextDevice, wantReadableHandle_)
35− wantReadableHandle_, hClose_help,
36− wantReadableHandle, wantWritableHandle)
37−import GHC.IO.Handle.Text (commitBuffer')
38−import GHC.IO.Handle.Types (BufferList(..), BufferMode(..), Handle__(..),
33+import GHC.IO.Handle.Types (Handle__(..), Newline(..))
39− Newline(..))
40import System.IO (Handle)
34import System.IO (Handle)
41import System.IO.Error (isEOFError)
35import System.IO.Error (isEOFError)
42import qualified Data.Text as T
36import qualified Data.Text as T
Data/Text/Lazy/IO.hs+5−12
@@ -44,20 +44,13 @@ import qualified Data.ByteString.Char8 as S8
44import qualified Data.ByteString.Lazy.Char8 as L8
44import qualified Data.ByteString.Lazy.Char8 as L8
45#else
45#else
46import Control.Exception (throw)
46import Control.Exception (throw)
47−import Data.IORef (readIORef, writeIORef)
47+import Data.IORef (readIORef)
48import Data.Text.IO.Internal (hGetLineWith, readChunk)
48import Data.Text.IO.Internal (hGetLineWith, readChunk)
49−import GHC.IO.Buffer (Buffer(..), BufferState(..), CharBufElem, CharBuffer,
49+import GHC.IO.Buffer (isEmptyBuffer)
50− RawCharBuffer, bufferAdjustL, bufferElems, charSize,
51− emptyBuffer, isEmptyBuffer, newCharBuffer, readCharBuf,
52− withRawBuffer, writeCharBuf)
53import GHC.IO.Exception (IOException(..), IOErrorType(..), ioException)
50import GHC.IO.Exception (IOException(..), IOErrorType(..), ioException)
54−import GHC.IO.Handle.Internals (augmentIOError, ioe_EOF, readTextDevice,
51+import GHC.IO.Handle.Internals (augmentIOError, hClose_help,
55− wantReadableHandle_, hClose_help,
56− wantReadableHandle, wantWritableHandle,
52+ wantReadableHandle, withHandle)
57− withHandle)
58−import GHC.IO.Handle.Text (commitBuffer')
53+import GHC.IO.Handle.Types (Handle__(..), HandleType(..))
59−import GHC.IO.Handle.Types (BufferList(..), BufferMode(..), Handle__(..),
60− HandleType(..), Newline(..))
61import System.IO.Error (isEOFError)
54import System.IO.Error (isEOFError)
62import System.IO.Unsafe (unsafeInterleaveIO)
55import System.IO.Unsafe (unsafeInterleaveIO)
63#endif
56#endif