@@ -59,13 +59,13 @@ module Streamly.Internal.Network.Inet.TCP
5959 -- , writeUtf8ByLines
6060 -- , writeByFrames
6161 , writeWithBufferOf
62− , fromBytes
63− , fromBytesWithBufferOf
62+ , putBytes
63+ , putBytesWithBufferOf
6464
6565 -- -- * Array Write
6666 -- , writeArray
6767 , writeChunks
68− , fromChunks
68+ , putChunks
6969
7070 -- ** Transformation
7171 , processBytes
@@ -332,15 +332,15 @@ toBytes addr port = AS.concat $ withConnection addr port ISK.toChunks
332332-- number.
333333--
334334-- @since 0.7.0
335−{-# INLINE fromChunks #-}
336−fromChunks
335+{-# INLINE putChunks #-}
336+putChunks
337337 :: (MonadCatch m, MonadAsync m)
338338 => (Word8, Word8, Word8, Word8)
339339 -> PortNumber
340340 -> SerialT m (Array Word8)
341341 -> m ()
342−fromChunks addr port xs =
343− S.drain $ withConnection addr port (\sk -> S.yieldM $ ISK.fromChunks sk xs)
342+putChunks addr port xs =
343+ S.drain $ withConnection addr port (\sk -> S.yieldM $ ISK.putChunks sk xs)
344344
345345-- | Write a stream of arrays to the supplied IPv4 host address and port
346346-- number.
@@ -373,15 +373,15 @@ writeChunks addr port = Fold step initial extract
373373-- input elements.
374374--
375375-- @since 0.7.0
376−{-# INLINE fromBytesWithBufferOf #-}
377−fromBytesWithBufferOf
376+{-# INLINE putBytesWithBufferOf #-}
377+putBytesWithBufferOf
378378 :: (MonadCatch m, MonadAsync m)
379379 => Int
380380 -> (Word8, Word8, Word8, Word8)
381381 -> PortNumber
382382 -> SerialT m Word8
383383 -> m ()
384−fromBytesWithBufferOf n addr port m = fromChunks addr port $ AS.arraysOf n m
384+putBytesWithBufferOf n addr port m = putChunks addr port $ AS.arraysOf n m
385385
386386-- | Like 'write' but provides control over the write buffer. Output will
387387-- be written to the IO device as soon as we collect the specified number of
@@ -401,10 +401,10 @@ writeWithBufferOf n addr port =
401401-- | Write a stream to the supplied IPv4 host address and port number.
402402--
403403-- @since 0.7.0
404−{-# INLINE fromBytes #-}
405−fromBytes :: (MonadCatch m, MonadAsync m)
404+{-# INLINE putBytes #-}
405+putBytes :: (MonadCatch m, MonadAsync m)
406406 => (Word8, Word8, Word8, Word8) -> PortNumber -> SerialT m Word8 -> m ()
407−fromBytes = fromBytesWithBufferOf defaultChunkSize
407+putBytes = putBytesWithBufferOf defaultChunkSize
408408
409409-- | Write a stream to the supplied IPv4 host address and port number.
410410--
@@ -432,7 +432,7 @@ withInputConnect addr port input f = S.bracket pre post handler
432432
433433 pre = do
434434 sk <- liftIO $ connect addr port
435− tid <- fork (ISK.fromBytes sk input)
435+ tid <- fork (ISK.putBytes sk input)
436436 return (sk, tid)
437437
438438 handler (sk, _) = f sk