diff options
author | Joey Hess <joeyh@joeyh.name> | 2015-11-17 17:27:24 -0400 |
---|---|---|
committer | Joey Hess <joeyh@joeyh.name> | 2015-11-17 17:27:24 -0400 |
commit | 6bf2d636864753eff8a5a31b6782f381f195806b (patch) | |
tree | dd1efa7378366962b6ee3dc214fa34aac4c0a8e3 /Utility/FileSystemEncoding.hs | |
parent | 9ed65a1226cc67000b12d768d6f5e8acaada1c65 (diff) |
use intercalate instead of MissingH's join
The two functions are identical.
Diffstat (limited to 'Utility/FileSystemEncoding.hs')
-rw-r--r-- | Utility/FileSystemEncoding.hs | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/Utility/FileSystemEncoding.hs b/Utility/FileSystemEncoding.hs index 2d9691d52..67341d371 100644 --- a/Utility/FileSystemEncoding.hs +++ b/Utility/FileSystemEncoding.hs @@ -29,6 +29,7 @@ import System.IO.Unsafe import qualified Data.Hash.MD5 as MD5 import Data.Word import Data.Bits.Utils +import Data.List import Data.List.Utils import qualified Data.ByteString.Lazy as L #ifdef mingw32_HOST_OS @@ -125,12 +126,12 @@ decodeW8 = s2w8 . _encodeFilePath {- Like encodeW8 and decodeW8, but NULs are passed through unchanged. -} encodeW8NUL :: [Word8] -> FilePath -encodeW8NUL = join nul . map encodeW8 . split (s2w8 nul) +encodeW8NUL = intercalate nul . map encodeW8 . split (s2w8 nul) where nul = ['\NUL'] decodeW8NUL :: FilePath -> [Word8] -decodeW8NUL = join (s2w8 nul) . map decodeW8 . split nul +decodeW8NUL = intercalate (s2w8 nul) . map decodeW8 . split nul where nul = ['\NUL'] |