Hello community,
here is the log from the commit of package ghc-fast-logger for openSUSE:Factory
checked in at 2019-04-28 20:12:47
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/ghc-fast-logger (Old)
and /work/SRC/openSUSE:Factory/.ghc-fast-logger.new.5536 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "ghc-fast-logger"
Sun Apr 28 20:12:47 2019 rev:15 rq:698550 version:2.4.15
Changes:
--------
--- /work/SRC/openSUSE:Factory/ghc-fast-logger/ghc-fast-logger.changes
2018-12-28 12:35:22.975960921 +0100
+++
/work/SRC/openSUSE:Factory/.ghc-fast-logger.new.5536/ghc-fast-logger.changes
2019-04-28 20:12:49.546441881 +0200
@@ -1,0 +2,15 @@
+Fri Apr 12 02:01:57 UTC 2019 - [email protected]
+
+- Update fast-logger to version 2.4.15.
+ Upstream has not updated the file "ChangeLog.md" since the last
+ release.
+
+-------------------------------------------------------------------
+Thu Apr 11 06:35:18 UTC 2019 - [email protected]
+
+- Update fast-logger to version 2.4.14.
+ ## 2.4.14
+
+ * Add `ToLogStr` instances for the following types: signed integers,
unsigned integers, floating-point numbers. These instances all use decimal
encodings. [#177](https://github.com/kazu-yamamoto/logger/pull/177)
+
+-------------------------------------------------------------------
Old:
----
fast-logger-2.4.13.tar.gz
New:
----
fast-logger-2.4.15.tar.gz
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ ghc-fast-logger.spec ++++++
--- /var/tmp/diff_new_pack.67VrU1/_old 2019-04-28 20:12:50.190441481 +0200
+++ /var/tmp/diff_new_pack.67VrU1/_new 2019-04-28 20:12:50.194441479 +0200
@@ -1,7 +1,7 @@
#
# spec file for package ghc-fast-logger
#
-# Copyright (c) 2018 SUSE LINUX GmbH, Nuernberg, Germany.
+# Copyright (c) 2019 SUSE LINUX GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
@@ -19,7 +19,7 @@
%global pkg_name fast-logger
%bcond_with tests
Name: ghc-%{pkg_name}
-Version: 2.4.13
+Version: 2.4.15
Release: 0
Summary: A fast logging system
License: BSD-3-Clause
++++++ fast-logger-2.4.13.tar.gz -> fast-logger-2.4.15.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/fast-logger-2.4.13/ChangeLog.md
new/fast-logger-2.4.15/ChangeLog.md
--- old/fast-logger-2.4.13/ChangeLog.md 2018-12-25 03:45:26.000000000 +0100
+++ new/fast-logger-2.4.15/ChangeLog.md 2019-04-11 07:09:10.000000000 +0200
@@ -1,3 +1,7 @@
+## 2.4.14
+
+* Add `ToLogStr` instances for the following types: signed integers, unsigned
integers, floating-point numbers. These instances all use decimal encodings.
[#177](https://github.com/kazu-yamamoto/logger/pull/177)
+
## 2.4.11
* Give an explicit definition for (<>) in LogStr's Semigroup instance.
[#155](https://github.com/kazu-yamamoto/logger/pull/155)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/fast-logger-2.4.13/System/Log/FastLogger/LogStr.hs
new/fast-logger-2.4.15/System/Log/FastLogger/LogStr.hs
--- old/fast-logger-2.4.13/System/Log/FastLogger/LogStr.hs 2018-12-25
03:45:26.000000000 +0100
+++ new/fast-logger-2.4.15/System/Log/FastLogger/LogStr.hs 2019-04-11
07:09:10.000000000 +0200
@@ -28,6 +28,8 @@
import qualified Data.Semigroup as Semi (Semigroup(..))
#endif
import Data.String (IsString(..))
+import Data.Int (Int8,Int16,Int32,Int64)
+import Data.Word (Word,Word8,Word16,Word32,Word64)
import qualified Data.Text as T
import qualified Data.Text.Encoding as T
import qualified Data.Text.Lazy as TL
@@ -67,6 +69,9 @@
instance IsString LogStr where
fromString = toLogStr . TL.pack
+-- | Types that can be converted to a 'LogStr'. Instances for
+-- types from the @text@ library use a UTF-8 encoding. Instances
+-- for numerical types use a decimal encoding.
class ToLogStr msg where
toLogStr :: msg -> LogStr
@@ -75,7 +80,7 @@
instance ToLogStr S8.ByteString where
toLogStr bs = LogStr (BS.length bs) (toBuilder bs)
instance ToLogStr BL.ByteString where
- toLogStr = toLogStr . S8.concat . BL.toChunks
+ toLogStr b = LogStr (fromIntegral (BL.length b)) (B.lazyByteString b)
instance ToLogStr Builder where
toLogStr x = let b = B.toLazyByteString x in LogStr (fromIntegral
(BL.length b)) (B.lazyByteString b)
instance ToLogStr String where
@@ -85,6 +90,48 @@
instance ToLogStr TL.Text where
toLogStr = toLogStr . TL.encodeUtf8
+-- | @since 2.4.14
+instance ToLogStr Int where
+ toLogStr = toLogStr . B.intDec
+-- | @since 2.4.14
+instance ToLogStr Int8 where
+ toLogStr = toLogStr . B.int8Dec
+-- | @since 2.4.14
+instance ToLogStr Int16 where
+ toLogStr = toLogStr . B.int16Dec
+-- | @since 2.4.14
+instance ToLogStr Int32 where
+ toLogStr = toLogStr . B.int32Dec
+-- | @since 2.4.14
+instance ToLogStr Int64 where
+ toLogStr = toLogStr . B.int64Dec
+
+-- | @since 2.4.14
+instance ToLogStr Word where
+ toLogStr = toLogStr . B.wordDec
+-- | @since 2.4.14
+instance ToLogStr Word8 where
+ toLogStr = toLogStr . B.word8Dec
+-- | @since 2.4.14
+instance ToLogStr Word16 where
+ toLogStr = toLogStr . B.word16Dec
+-- | @since 2.4.14
+instance ToLogStr Word32 where
+ toLogStr = toLogStr . B.word32Dec
+-- | @since 2.4.14
+instance ToLogStr Word64 where
+ toLogStr = toLogStr . B.word64Dec
+
+-- | @since 2.4.14
+instance ToLogStr Integer where
+ toLogStr = toLogStr . B.integerDec
+-- | @since 2.4.14
+instance ToLogStr Float where
+ toLogStr = toLogStr . B.floatDec
+-- | @since 2.4.14
+instance ToLogStr Double where
+ toLogStr = toLogStr . B.doubleDec
+
instance Show LogStr where
show = show . T.decodeUtf8 . fromLogStr
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/fast-logger-2.4.13/fast-logger.cabal
new/fast-logger-2.4.15/fast-logger.cabal
--- old/fast-logger-2.4.13/fast-logger.cabal 2018-12-25 03:45:26.000000000
+0100
+++ new/fast-logger-2.4.15/fast-logger.cabal 2019-04-11 07:09:10.000000000
+0200
@@ -1,5 +1,5 @@
Name: fast-logger
-Version: 2.4.13
+Version: 2.4.15
Author: Kazu Yamamoto <[email protected]>
Maintainer: Kazu Yamamoto <[email protected]>
License: BSD3
@@ -44,6 +44,7 @@
Ghc-Options: -Wall -threaded
Other-Modules: FastLoggerSpec
+ Build-Tools: hspec-discover >= 2.6
Build-Depends: base >= 4 && < 5
, bytestring
, directory