File tree Expand file tree Collapse file tree 2 files changed +3
-3
lines changed Expand file tree Collapse file tree 2 files changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -1341,7 +1341,7 @@ span p t = case span_ p t of
1341
1341
-- >>> T.spanEnd (=='0') "AB000"
1342
1342
-- ("AB","000")
1343
1343
spanEnd :: (Char -> Bool ) -> Text -> (Text , Text )
1344
- spanEnd p t = case spanEnd_ p t of (# hd, tl # ) -> (hd, tl)
1344
+ spanEnd p t = case spanEnd_ p t of (# hd,tl # ) -> (hd,tl)
1345
1345
{-# inline spanEnd #-}
1346
1346
1347
1347
-- | /O(n)/ 'break' is like 'span', but the prefix returned is
Original file line number Diff line number Diff line change @@ -32,13 +32,13 @@ span_ p t@(Text arr off len) = (# hd,tl #)
32
32
{-# INLINE span_ #-}
33
33
34
34
spanEnd_ :: (Char -> Bool ) -> Text -> (# Text , Text # )
35
- spanEnd_ p t@ (Text arr off len) = (# hd, tl # )
35
+ spanEnd_ p t@ (Text arr off len) = (# hd,tl # )
36
36
where hd = text arr off (k+ 1 )
37
37
tl = text arr (off+ k+ 1 ) (len- k- 1 )
38
38
! k = loop (len- 1 )
39
39
loop ! i | i >= off && p c = loop (i+ d)
40
40
| otherwise = i
41
- where (c, d) = reverseIter t i
41
+ where (c,d) = reverseIter t i
42
42
{-# INLINE spanEnd_ #-}
43
43
44
44
runText :: (forall s . (A. MArray s -> Int -> ST s Text ) -> ST s Text ) -> Text
You can’t perform that action at this time.
0 commit comments