Skip to content

Commit

Permalink
Change the type signatures of toStrict and fromStrict
Browse files Browse the repository at this point in the history
  • Loading branch information
Kleidukos authored and Lysxia committed Dec 13, 2023
1 parent fb3aed2 commit 30637ae
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/Data/Text/Lazy.hs
Original file line number Diff line number Diff line change
Expand Up @@ -442,12 +442,12 @@ toChunks :: Text -> [T.Text]
toChunks cs = foldrChunks (:) [] cs

-- | /O(n)/ Convert a lazy 'Text' into a strict 'T.Text'.
toStrict :: Text -> T.Text
toStrict :: LazyText -> T.StrictText
toStrict t = T.concat (toChunks t)
{-# INLINE [1] toStrict #-}

-- | /O(c)/ Convert a strict 'T.Text' into a lazy 'Text'.
fromStrict :: T.Text -> Text
fromStrict :: T.StrictText -> LazyText
fromStrict t = chunk t Empty
{-# INLINE [1] fromStrict #-}

Expand Down

0 comments on commit 30637ae

Please sign in to comment.