module Hydra.Impl.Haskell.Ext.Bytestrings where

import qualified Data.ByteString.Lazy as BS
import qualified Data.Text.Lazy.Encoding as DTE
import qualified Data.Text.Lazy as TL


bytesToString :: BS.ByteString -> String
bytesToString :: ByteString -> String
bytesToString = Text -> String
TL.unpack forall b c a. (b -> c) -> (a -> b) -> a -> c
. ByteString -> Text
DTE.decodeUtf8

stringToBytes :: String -> BS.ByteString
stringToBytes :: String -> ByteString
stringToBytes = Text -> ByteString
DTE.encodeUtf8 forall b c a. (b -> c) -> (a -> b) -> a -> c
. String -> Text
TL.pack