Hello community,

here is the log from the commit of package ghc-text-all for openSUSE:Factory 
checked in at 2017-08-31 21:00:26
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/ghc-text-all (Old)
 and      /work/SRC/openSUSE:Factory/.ghc-text-all.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "ghc-text-all"

Thu Aug 31 21:00:26 2017 rev:3 rq:513513 version:0.4.1.1

Changes:
--------
--- /work/SRC/openSUSE:Factory/ghc-text-all/ghc-text-all.changes        
2017-05-17 10:55:33.596649731 +0200
+++ /work/SRC/openSUSE:Factory/.ghc-text-all.new/ghc-text-all.changes   
2017-08-31 21:00:28.309625604 +0200
@@ -1,0 +2,5 @@
+Thu Jul 27 14:07:27 UTC 2017 - psim...@suse.com
+
+- Update to version 0.4.1.1.
+
+-------------------------------------------------------------------

Old:
----
  text-all-0.3.1.0.tar.gz

New:
----
  text-all-0.4.1.1.tar.gz

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ ghc-text-all.spec ++++++
--- /var/tmp/diff_new_pack.ZmzYtr/_old  2017-08-31 21:00:29.509457024 +0200
+++ /var/tmp/diff_new_pack.ZmzYtr/_new  2017-08-31 21:00:29.529454215 +0200
@@ -18,7 +18,7 @@
 
 %global pkg_name text-all
 Name:           ghc-%{pkg_name}
-Version:        0.3.1.0
+Version:        0.4.1.1
 Release:        0
 Summary:        Everything Data.Text related in one package
 License:        BSD-3-Clause
@@ -26,10 +26,11 @@
 Url:            https://hackage.haskell.org/package/%{pkg_name}
 Source0:        
https://hackage.haskell.org/package/%{pkg_name}-%{version}/%{pkg_name}-%{version}.tar.gz
 BuildRequires:  ghc-Cabal-devel
+BuildRequires:  ghc-bytestring-devel
 BuildRequires:  ghc-rpm-macros
 BuildRequires:  ghc-text-devel
 BuildRequires:  ghc-text-format-devel
-BuildRequires:  ghc-text-show-devel
+BuildRequires:  ghc-utf8-string-devel
 BuildRoot:      %{_tmppath}/%{name}-%{version}-build
 
 %description

++++++ text-all-0.3.1.0.tar.gz -> text-all-0.4.1.1.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/text-all-0.3.1.0/CHANGELOG.md 
new/text-all-0.4.1.1/CHANGELOG.md
--- old/text-all-0.3.1.0/CHANGELOG.md   2017-04-23 23:29:06.000000000 +0200
+++ new/text-all-0.4.1.1/CHANGELOG.md   2017-07-11 17:22:29.000000000 +0200
@@ -1,18 +1,39 @@
+# 0.4.1.1
+
+* Dropped compatibility with GHC 7.4.2 and added a lower bound for
+  `bytestring`.
+
+# 0.4.1.0
+
+* Now `toString` and other functions work with `ByteString` as well. Lenient
+  UTF-8 decoding is used.
+
+* Added `toByteString` and `toLByteString`.
+
+# 0.4.0.0
+
+* Dropped `text-show` entirely; now `show` works via `Prelude.show`, which is
+  slower but avoids a heavy dependency. It is recommended to use
+  `text-format`, `formatting` or `fmt` if fast formatting is needed.
+  
+* Added `show` and `format` to `Data.Text.Lazy.All`.
+
 # 0.3.1.0
 
-* Bumped the text-show upper bound. (text-show added some instances.)
+* Bumped the `text-show` upper bound. (`text-show` added some instances.)
 
 # 0.3.0.2
 
-* Bumped the text-show upper bound.
+* Bumped the `text-show` upper bound.
 
 # 0.3.0.1
 
-* Bumped the text-show upper bound.
+* Bumped the `text-show` upper bound.
 
 # 0.3.0.0
 
-* Replaced functions like `strictToBuilder` with conversion typeclasses (i.e. 
now it's just `toStrict`, `toLazy`, `toBuilder`, and `toString`).
+* Replaced functions like `strictToBuilder` with conversion typeclasses (i.e.
+  now it's just `toStrict`, `toLazy`, `toBuilder`, and `toString`).
 
 # 0.2.0.0
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/text-all-0.3.1.0/lib/Data/Text/All.hs 
new/text-all-0.4.1.1/lib/Data/Text/All.hs
--- old/text-all-0.3.1.0/lib/Data/Text/All.hs   2017-04-23 23:29:06.000000000 
+0200
+++ new/text-all-0.4.1.1/lib/Data/Text/All.hs   2017-07-11 17:22:29.000000000 
+0200
@@ -1,16 +1,15 @@
-{-# LANGUAGE
-GADTs,
-TypeSynonymInstances
-  #-}
+{-# LANGUAGE GADTs #-}
+{-# LANGUAGE TypeSynonymInstances #-}
 
 
-{- |
-Here are the nice things from text that you get (thanks to a restrictive lower 
bound) but that aren't documented elsewhere in this module:
+{- | Note that thanks to a restrictive lower bound on @text@, you can be sure
+that the following things will be present in the "Data.Text" reexport:
 
 * The 'T.takeWhileEnd' function.
-* An instance for @Semigroup@.
-* An instance for @printf@ (i.e. you can use a 'Text' as one of @printf@'s 
arguments).
-* An instance for @Binary@.
+* An instance for @Semigroup Text@.
+* An instance for @Binary Text@.
+* An instance for 'Text.Printf.printf' (i.e. you can use a 'Text' as one of
+  @printf@'s arguments).
 -}
 module Data.Text.All
 (
@@ -24,17 +23,14 @@
 
   -- * Conversion
   -- $conversion
-  toStrict, toLazy, toBuilder, toString,
+  toStrict, toLazy,
+  toBuilder,
+  toString,
+  toByteString, toLByteString,
 
   -- * Showing
   -- $showing
-
-  -- ** Strict 'Text'
-  show, show',
-  -- ** Lazy 'Text'
-  lshow, lshow',
-  -- ** 'Builder'
-  bshow, bshow',
+  show, lshow, bshow,
 
   -- * Formatting
   -- $formatting
@@ -53,12 +49,18 @@
 import Data.Text
 import Data.Text.IO
 import Data.Text.Encoding
+import Data.Text.Encoding.Error
 import qualified Data.Text.Lazy.Builder as B
-import Data.Text.Lazy.Builder (Builder)
+import Data.Text.Lazy.Builder (Builder, flush)
 
 import qualified Data.Text.Lazy as TL
+import qualified Data.Text.Lazy.Encoding as TL
+
+import qualified Data.ByteString as BS
+import qualified Data.ByteString.Lazy as BSL
 
-import TextShow hiding (Builder, toString)
+import qualified Data.ByteString.UTF8 as UTF8
+import qualified Data.ByteString.Lazy.UTF8 as UTF8L
 
 import Data.Text.Format hiding (format, print, hprint, build)
 import Data.Text.Format.Params
@@ -72,38 +74,27 @@
 
 {- $showing
 
-'show' is a fast variant of @show@ for 'Text' \/ 'Builder' that only works for 
some types – it's very fast for 'Int', etc, but doesn't work for types that you 
have defined yourself. (If you want more instances, import 
<https://hackage.haskell.org/package/text-show-instances text-show-instances>.)
-
-'show'' is a shortcut for @pack.show@ that works for everything with a 'Show' 
instance but is slower.
+Variants below use 'P.show' from "Prelude". If you want faster showing,
+either use <https://hackage.haskell.org/package/text-show text-show> or some
+formatting library.
 -}
 
-show :: TextShow a => a -> Text
-show = showt
+show :: Show a => a -> Text
+show = pack . P.show
 {-# INLINE show #-}
 
-lshow :: TextShow a => a -> LText
-lshow = showtl
+lshow :: Show a => a -> LText
+lshow = TL.pack . P.show
 {-# INLINE lshow #-}
 
-bshow :: TextShow a => a -> Builder
-bshow = showb
+bshow :: Show a => a -> Builder
+bshow = B.fromString . P.show
 {-# INLINE bshow #-}
 
-show' :: Show a => a -> Text
-show' = pack . P.show
-{-# INLINE show' #-}
-
-lshow' :: Show a => a -> LText
-lshow' = TL.pack . P.show
-{-# INLINE lshow' #-}
-
-bshow' :: Show a => a -> Builder
-bshow' = B.fromString . P.show
-{-# INLINE bshow' #-}
-
 {- $formatting
 
-'format' is a function similar to @printf@ in spirit. Don't forget to enable 
@OverloadedStrings@ if you want to use it!
+'format' is a function similar to @printf@ in spirit. Don't forget to enable
+@OverloadedStrings@ if you want to use it!
 
 >>> format "{}+{}={}" (2, 2, 4)
 "2+2=4"
@@ -133,8 +124,9 @@
 bformat = Format.build
 {-# INLINE bformat #-}
 
-{- $conversion
-These functions can convert from strict\/lazy 'Text', 'Builder', and 'String'.
+{- $conversion These functions can convert from strict\/lazy 'Text', 'Builder',
+'String', and strict\/lazy 'BS.ByteString' (in which case they use lenient
+UTF-8 decoding).
 -}
 
 class ToStrict t where
@@ -148,6 +140,12 @@
 instance ToStrict Builder where
     toStrict = TL.toStrict . B.toLazyText
     {-# INLINE toStrict #-}
+instance ToStrict BS.ByteString where
+    toStrict = decodeUtf8With lenientDecode
+    {-# INLINE toStrict #-}
+instance ToStrict BSL.ByteString where
+    toStrict = decodeUtf8With lenientDecode . BSL.toStrict
+    {-# INLINE toStrict #-}
 
 class ToLazy t where
     toLazy :: t -> LText
@@ -160,6 +158,12 @@
 instance ToLazy Builder where
     toLazy = B.toLazyText
     {-# INLINE toLazy #-}
+instance ToLazy BS.ByteString where
+    toLazy = TL.fromStrict . decodeUtf8With lenientDecode
+    {-# INLINE toLazy #-}
+instance ToLazy BSL.ByteString where
+    toLazy = TL.decodeUtf8With lenientDecode
+    {-# INLINE toLazy #-}
 
 class ToBuilder t where
     toBuilder :: t -> Builder
@@ -172,6 +176,12 @@
 instance ToBuilder LText where
     toBuilder = B.fromLazyText
     {-# INLINE toBuilder #-}
+instance ToBuilder BS.ByteString where
+    toBuilder = B.fromText . decodeUtf8With lenientDecode
+    {-# INLINE toBuilder #-}
+instance ToBuilder BSL.ByteString where
+    toBuilder = B.fromLazyText . TL.decodeUtf8With lenientDecode
+    {-# INLINE toBuilder #-}
 
 class ToString t where
     toString :: t -> String
@@ -184,6 +194,42 @@
 instance ToString Builder where
     toString = TL.unpack . B.toLazyText
     {-# INLINE toString #-}
+instance ToString BS.ByteString where
+    toString = UTF8.toString
+    {-# INLINE toString #-}
+instance ToString BSL.ByteString where
+    toString = UTF8L.toString
+    {-# INLINE toString #-}
+
+class ToByteString t where
+    toByteString :: t -> BS.ByteString
+instance ToByteString Text where
+    toByteString = encodeUtf8
+    {-# INLINE toByteString #-}
+instance ToByteString LText where
+    toByteString = encodeUtf8 . TL.toStrict
+    {-# INLINE toByteString #-}
+instance ToByteString Builder where
+    toByteString = encodeUtf8 . TL.toStrict . B.toLazyText
+    {-# INLINE toByteString #-}
+instance (a ~ Char) => ToByteString [a] where
+    toByteString = UTF8.fromString
+    {-# INLINE toByteString #-}
+
+class ToLByteString t where
+    toLByteString :: t -> BSL.ByteString
+instance ToLByteString Text where
+    toLByteString = TL.encodeUtf8 . TL.fromStrict
+    {-# INLINE toLByteString #-}
+instance ToLByteString LText where
+    toLByteString = TL.encodeUtf8
+    {-# INLINE toLByteString #-}
+instance ToLByteString Builder where
+    toLByteString = TL.encodeUtf8 . B.toLazyText
+    {-# INLINE toLByteString #-}
+instance (a ~ Char) => ToLByteString [a] where
+    toLByteString = UTF8L.fromString
+    {-# INLINE toLByteString #-}
 
 -- | A 'Builder' producing a single character.
 bsingleton :: Char -> Builder
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/text-all-0.3.1.0/lib/Data/Text/Lazy/All.hs 
new/text-all-0.4.1.1/lib/Data/Text/Lazy/All.hs
--- old/text-all-0.3.1.0/lib/Data/Text/Lazy/All.hs      2017-04-23 
23:29:06.000000000 +0200
+++ new/text-all-0.4.1.1/lib/Data/Text/Lazy/All.hs      2017-07-11 
17:22:29.000000000 +0200
@@ -4,6 +4,9 @@
   module Data.Text.Lazy,
   module Data.Text.Lazy.IO,
   module Data.Text.Lazy.Encoding,
+
+  -- * Lazy text functions
+  show, format,
 )
 where
 
@@ -11,3 +14,12 @@
 import Data.Text.Lazy
 import Data.Text.Lazy.IO
 import Data.Text.Lazy.Encoding
+import Data.Text.Format (format)
+import qualified Prelude as P
+import Prelude hiding (show)
+
+
+-- | A synonym for 'Data.Text.All.lshow'.
+show :: Show a => a -> Text
+show = pack . P.show
+{-# INLINE show #-}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/text-all-0.3.1.0/text-all.cabal 
new/text-all-0.4.1.1/text-all.cabal
--- old/text-all-0.3.1.0/text-all.cabal 2017-04-23 23:29:06.000000000 +0200
+++ new/text-all-0.4.1.1/text-all.cabal 2017-07-11 17:22:29.000000000 +0200
@@ -1,5 +1,5 @@
 name:                text-all
-version:             0.3.1.0
+version:             0.4.1.1
 synopsis:            Everything Data.Text related in one package
 description:
   Everything @Data.Text@-related in one package.
@@ -13,7 +13,7 @@
 maintainer:          y...@artyom.me
 -- copyright:           
 category:            Text
-tested-with:         GHC == 7.4.2, GHC == 7.6.3, GHC == 7.8.4, GHC == 7.10.3, 
GHC == 8.0.1
+tested-with:         GHC == 7.6.3, GHC == 7.8.4, GHC == 7.10.3, GHC == 8.0.1
 build-type:          Simple
 extra-source-files:  CHANGELOG.md
 cabal-version:       >=1.10
@@ -28,9 +28,10 @@
   -- other-modules:       
   -- other-extensions:    
   build-depends:       base >=4.5 && <5
+                     , bytestring >= 0.10
                      , text ==1.2.2.*
-                     , text-show >=3.2 && <3.7
                      , text-format ==0.3.1.*
+                     , utf8-string
   ghc-options:         -Wall -fno-warn-unused-do-bind
   hs-source-dirs:      lib
   default-language:    Haskell2010


Reply via email to