summaryrefslogtreecommitdiff
path: root/Presence/ByteStringOperators.hs
blob: 8ecb214b2902036565ef97fedf26c07531b40320 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
module ByteStringOperators where

import qualified Data.ByteString as S (ByteString)
import Data.ByteString.Lazy.Char8 as L 

(<++>) :: ByteString -> ByteString -> ByteString
(<++.>) :: ByteString -> S.ByteString -> ByteString
(<.++>) :: S.ByteString -> ByteString -> ByteString
(<.++.>) :: S.ByteString -> S.ByteString -> ByteString
a <++> b =  L.append a b
a <++.> b = L.append a (fromChunks [b])
a <.++> b = L.append (fromChunks [a]) b
a <.++.> b = fromChunks [a,b]
infixr 5 <.++.>
infixr 5 <.++>
infixr 5 <++>
infixr 5 <++.>