File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 11### 2.1.2
22
3+ * [ Update case mappings for Unicode 16.0] ( https://github.com/haskell/text/pull/618 )
4+
35* [ Add type synonym for lazy builders. Deprecated ` StrictBuilder ` for ` StrictTextBuilder ` ] ( https://github.com/haskell/text/pull/581 )
46
7+ * [ Add ` initsNE ` and ` tailsNE ` ] ( https://github.com/haskell/text/pull/558 )
8+
9+ * [ Add ` foldlM' ` ] ( https://github.com/haskell/text/pull/543 )
10+
11+ * [ Add ` Data.Text.Foreign.peekCString ` ] ( https://github.com/haskell/text/pull/599 )
12+
13+ * [ Add ` Data.Text.show ` and ` Data.Text.Lazy.show ` ] ( https://github.com/haskell/text/pull/608 )
14+
15+ * [ Add pattern synonyms ` Empty ` , ` (:<) ` , and ` (:>) ` ] ( https://github.com/haskell/text/pull/619 )
16+
17+ * [ Improve precision of ` Data.Text.Read.rational ` ] ( https://github.com/haskell/text/pull/565 )
18+
19+ * [ ` Data.Text.IO.Utf8 ` : use ` B.putStrLn ` instead of ` B.putStr t >> B.putStr "\n" ` ] ( https://github.com/haskell/text/pull/579 )
20+
21+ * [ ` Data.Text.IO ` and ` Data.Text.Lazy.IO ` : Make ` putStrLn ` more atomic with line or block buffering] ( https://github.com/haskell/text/pull/600 )
22+
23+ * [ Integrate UTF-8 ` hPutStr ` to standard ` hPutStr ` ] ( https://github.com/haskell/text/pull/589 )
24+
25+ * [ Serialise ` Text ` without going through ` ByteString ` ] ( https://github.com/haskell/text/pull/617 )
26+
27+ * [ Make ` splitAt ` strict in its first argument, even if input is empty] ( https://github.com/haskell/text/pull/575 )
28+
29+ * [ Improve lazy performance of ` Data.Text.Lazy.inits ` ] ( https://github.com/haskell/text/pull/572 )
30+
31+ * [ Implement ` Data.Text.unpack ` and ` Data.Text.toTitle ` directly, without streaming] ( https://github.com/haskell/text/pull/611 )
32+
33+ * [ Make ` fromString ` ` INLINEABLE ` instead of ` INLINE ` ] ( https://github.com/haskell/text/pull/571 ) to reduce the size of generated code.
34+
535### 2.1.1
636
737* Add pure Haskell implementations as an alternative to C-based ones,
Original file line number Diff line number Diff line change @@ -1041,6 +1041,8 @@ foldl1' f t = S.foldl1' f (stream t)
10411041{-# INLINE foldl1' #-}
10421042
10431043-- | /O(n)/ A monadic version of 'foldl''.
1044+ --
1045+ -- @since 2.1.2
10441046foldlM' :: Monad m => (a -> Char -> m a ) -> a -> Text -> m a
10451047foldlM' f z t = S. foldlM' f z (stream t)
10461048{-# INLINE foldlM' #-}
@@ -2096,6 +2098,8 @@ overflowError :: HasCallStack => String -> a
20962098overflowError fun = P. error $ " Data.Text." ++ fun ++ " : size overflow"
20972099
20982100-- | Convert a value to 'Text'.
2101+ --
2102+ -- @since 2.1.2
20992103show :: Show a => a -> Text
21002104show = pack . P. show
21012105
Original file line number Diff line number Diff line change @@ -51,6 +51,8 @@ import qualified Data.Text as T
5151
5252data Text = Empty
5353 -- ^ Empty text.
54+ --
55+ -- @since 2.1.2
5456 | Chunk {- # UNPACK #-} !T. Text Text
5557 -- ^ Chunks must be non-empty, this invariant is not checked.
5658 deriving (Typeable )
Original file line number Diff line number Diff line change @@ -853,6 +853,7 @@ foldl1' f t = S.foldl1' f (stream t)
853853
854854-- | /O(n)/ A monadic version of 'foldl''.
855855--
856+ -- @since 2.1.2
856857foldlM' :: Monad m => (a -> Char -> m a ) -> a -> Text -> m a
857858foldlM' f z t = S. foldlM' f z (stream t)
858859{-# INLINE foldlM' #-}
@@ -1828,6 +1829,8 @@ zipWith f t1 t2 = unstream (S.zipWith g (stream t1) (stream t2))
18281829{-# INLINE [0] zipWith #-}
18291830
18301831-- | Convert a value to lazy 'Text'.
1832+ --
1833+ -- @since 2.1.2
18311834show :: Show a => a -> Text
18321835show = pack . P. show
18331836
You can’t perform that action at this time.
0 commit comments