on master help sign in
Fix a nasty space leak
5a125aeBryan O'Sullivan
Data/Text/Lazy/Search.hs+1−1
@@ -103,7 +103,7 @@ indices _ _ = []
103-- the possibility that the caller might try to access one element
103-- the possibility that the caller might try to access one element
104-- past the end.
104-- past the end.
105index :: T.Text -> Text -> Int64 -> Word16
105index :: T.Text -> Text -> Int64 -> Word16
106−index (T.Text arr off len) xs i
106+index (T.Text arr off len) xs !i
107 | j < len = A.unsafeIndex arr (off+j)
107 | j < len = A.unsafeIndex arr (off+j)
108 | otherwise = case xs of
108 | otherwise = case xs of
109 Empty
109 Empty