@@ -109,10 +109,10 @@ contains (W8# word#) (Utf8 ba#) =
109 containsHelp word# ba# 0# (sizeofByteArray# ba#)
109 containsHelp word# ba# 0# (sizeofByteArray# ba#)
112−containsHelp :: Word# -> ByteArray# -> Int# -> Int# -> Bool
112+containsHelp :: Word8# -> ByteArray# -> Int# -> Int# -> Bool
113containsHelp word# ba# !offset# len# =
113containsHelp word# ba# !offset# len# =
114 if isTrue# (offset# <# len#) then
114 if isTrue# (offset# <# len#) then
115− if isTrue# (eqWord# word# (indexWord8Array# ba# offset#))
115+ if isTrue# (eqWord8# word# (indexWord8Array# ba# offset#))
116 then True
116 then True
117 else containsHelp word# ba# (offset# +# 1#) len#
117 else containsHelp word# ba# (offset# +# 1#) len#
@@ -145,7 +145,7 @@ startsWithChar isGood bytes@(Utf8 ba#) =
148− !w# = indexWord8Array# ba# 0#
148+ !w# = word8ToWord# (indexWord8Array# ba# 0#)
150 | isTrue# (ltWord# w# 0xC0##) = C# (chr# (word2Int# w#))
150 | isTrue# (ltWord# w# 0xC0##) = C# (chr# (word2Int# w#))
151 | isTrue# (ltWord# w# 0xE0##) = chr2 ba# 0# w#
151 | isTrue# (ltWord# w# 0xE0##) = chr2 ba# 0# w#
@@ -164,7 +164,7 @@ endsWithWord8 (W8# w#) (Utf8 ba#) =
164 let len# = sizeofByteArray# ba# in
164 let len# = sizeofByteArray# ba# in
165 isTrue# (len# ># 0#)
165 isTrue# (len# ># 0#)
167− isTrue# (eqWord# w# (indexWord8Array# ba# (len# -# 1#)))
167+ isTrue# (eqWord8# w# (indexWord8Array# ba# (len# -# 1#)))
@@ -186,11 +186,11 @@ splitHelp str start offsets =
186 unsafeSlice str start offset : splitHelp str (offset + 1) offsets
186 unsafeSlice str start offset : splitHelp str (offset + 1) offsets
189−findDividers :: Word# -> ByteArray# -> Int# -> Int# -> [Int] -> [Int]
189+findDividers :: Word8# -> ByteArray# -> Int# -> Int# -> [Int] -> [Int]
190findDividers divider# ba# !offset# len# revOffsets =
190findDividers divider# ba# !offset# len# revOffsets =
191 if isTrue# (offset# <# len#) then
191 if isTrue# (offset# <# len#) then
192 findDividers divider# ba# (offset# +# 1#) len# $
192 findDividers divider# ba# (offset# +# 1#) len# $
193− if isTrue# (eqWord# divider# (indexWord8Array# ba# offset#))
193+ if isTrue# (eqWord8# divider# (indexWord8Array# ba# offset#))
194 then I# offset# : revOffsets
194 then I# offset# : revOffsets
195 else revOffsets
195 else revOffsets
@@ -353,7 +353,7 @@ toCharsHelp ba# offset# len# =
356− !w# = indexWord8Array# ba# offset#
356+ !w# = word8ToWord# (indexWord8Array# ba# offset#)
357 !(# char, width# #)
357 !(# char, width# #)
358 | isTrue# (ltWord# w# 0xC0##) = (# C# (chr# (word2Int# w#)), 1# #)
358 | isTrue# (ltWord# w# 0xC0##) = (# C# (chr# (word2Int# w#)), 1# #)
359 | isTrue# (ltWord# w# 0xE0##) = (# chr2 ba# offset# w#, 2# #)
359 | isTrue# (ltWord# w# 0xE0##) = (# chr2 ba# offset# w#, 2# #)
@@ -370,7 +370,7 @@ chr2 :: ByteArray# -> Int# -> Word# -> Char
370chr2 ba# offset# firstWord# =
370chr2 ba# offset# firstWord# =
372 !i1# = word2Int# firstWord#
372 !i1# = word2Int# firstWord#
373− !i2# = word2Int# (indexWord8Array# ba# (offset# +# 1#))
373+ !i2# = word2Int# (word8ToWord# (indexWord8Array# ba# (offset# +# 1#)))
374 !c1# = uncheckedIShiftL# (i1# -# 0xC0#) 6#
374 !c1# = uncheckedIShiftL# (i1# -# 0xC0#) 6#
375 !c2# = i2# -# 0x80#
375 !c2# = i2# -# 0x80#
@@ -382,8 +382,8 @@ chr3 :: ByteArray# -> Int# -> Word# -> Char
382chr3 ba# offset# firstWord# =
382chr3 ba# offset# firstWord# =
384 !i1# = word2Int# firstWord#
384 !i1# = word2Int# firstWord#
385− !i2# = word2Int# (indexWord8Array# ba# (offset# +# 1#))
385+ !i2# = word2Int# (word8ToWord# (indexWord8Array# ba# (offset# +# 1#)))
386− !i3# = word2Int# (indexWord8Array# ba# (offset# +# 2#))
386+ !i3# = word2Int# (word8ToWord# (indexWord8Array# ba# (offset# +# 2#)))
387 !c1# = uncheckedIShiftL# (i1# -# 0xE0#) 12#
387 !c1# = uncheckedIShiftL# (i1# -# 0xE0#) 12#
388 !c2# = uncheckedIShiftL# (i2# -# 0x80#) 6#
388 !c2# = uncheckedIShiftL# (i2# -# 0x80#) 6#
389 !c3# = i3# -# 0x80#
389 !c3# = i3# -# 0x80#
@@ -396,9 +396,9 @@ chr4 :: ByteArray# -> Int# -> Word# -> Char
396chr4 ba# offset# firstWord# =
396chr4 ba# offset# firstWord# =
398 !i1# = word2Int# firstWord#
398 !i1# = word2Int# firstWord#
399− !i2# = word2Int# (indexWord8Array# ba# (offset# +# 1#))
399+ !i2# = word2Int# (word8ToWord# (indexWord8Array# ba# (offset# +# 1#)))
400− !i3# = word2Int# (indexWord8Array# ba# (offset# +# 2#))
400+ !i3# = word2Int# (word8ToWord# (indexWord8Array# ba# (offset# +# 2#)))
401− !i4# = word2Int# (indexWord8Array# ba# (offset# +# 3#))
401+ !i4# = word2Int# (word8ToWord# (indexWord8Array# ba# (offset# +# 3#)))
402 !c1# = uncheckedIShiftL# (i1# -# 0xF0#) 18#
402 !c1# = uncheckedIShiftL# (i1# -# 0xF0#) 18#
403 !c2# = uncheckedIShiftL# (i2# -# 0x80#) 12#
403 !c2# = uncheckedIShiftL# (i2# -# 0x80#) 12#
404 !c3# = uncheckedIShiftL# (i3# -# 0x80#) 6#
404 !c3# = uncheckedIShiftL# (i3# -# 0x80#) 6#
@@ -473,7 +473,7 @@ toEscapedBuilderHelp before after !name@(Utf8 ba#) k =
473escape :: Word8 -> Word8 -> Ptr a -> Utf8 t -> Int -> Int -> Int -> IO ()
473escape :: Word8 -> Word8 -> Ptr a -> Utf8 t -> Int -> Int -> Int -> IO ()
474escape before@(W8# before#) after ptr name@(Utf8 ba#) offset@(I# offset#) len@(I# len#) i@(I# i#) =
474escape before@(W8# before#) after ptr name@(Utf8 ba#) offset@(I# offset#) len@(I# len#) i@(I# i#) =
475 if isTrue# (i# <# len#) then
475 if isTrue# (i# <# len#) then
476− if isTrue# (eqWord# before# (indexWord8Array# ba# (offset# +# i#)))
476+ if isTrue# (eqWord8# before# (indexWord8Array# ba# (offset# +# i#)))
478 do writeWordToPtr ptr i after
478 do writeWordToPtr ptr i after
479 escape before after ptr name offset len (i + 1)
479 escape before after ptr name offset len (i + 1)