Hello community,

here is the log from the commit of package perl-JSON for openSUSE:Factory 
checked in at 2019-02-04 21:22:36
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/perl-JSON (Old)
 and      /work/SRC/openSUSE:Factory/.perl-JSON.new.28833 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "perl-JSON"

Mon Feb  4 21:22:36 2019 rev:24 rq:667408 version:4.01

Changes:
--------
--- /work/SRC/openSUSE:Factory/perl-JSON/perl-JSON.changes      2018-12-19 
13:23:48.669353031 +0100
+++ /work/SRC/openSUSE:Factory/.perl-JSON.new.28833/perl-JSON.changes   
2019-02-04 21:22:41.859635500 +0100
@@ -1,0 +2,10 @@
+Mon Jan 21 06:12:43 UTC 2019 - Stephan Kulow <[email protected]>
+
+- updated to 4.01
+   see /usr/share/doc/packages/perl-JSON/Changes
+
+  4.01 2019-01-21
+      - added boolean function/method that takes a scalar value and
+        returns a boolean value (David Cantrell)
+
+-------------------------------------------------------------------

Old:
----
  JSON-4.00.tar.gz

New:
----
  JSON-4.01.tar.gz

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

Other differences:
------------------
++++++ perl-JSON.spec ++++++
--- /var/tmp/diff_new_pack.bPvaTi/_old  2019-02-04 21:22:42.463635354 +0100
+++ /var/tmp/diff_new_pack.bPvaTi/_new  2019-02-04 21:22:42.463635354 +0100
@@ -1,7 +1,7 @@
 #
 # spec file for package perl-JSON
 #
-# 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
@@ -17,7 +17,7 @@
 
 
 Name:           perl-JSON
-Version:        4.00
+Version:        4.01
 Release:        0
 %define cpan_name JSON
 Summary:        JSON (JavaScript Object Notation) encoder/decoder

++++++ JSON-4.00.tar.gz -> JSON-4.01.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/JSON-4.00/Changes new/JSON-4.01/Changes
--- old/JSON-4.00/Changes       2018-12-06 18:30:21.000000000 +0100
+++ new/JSON-4.01/Changes       2019-01-20 16:36:32.000000000 +0100
@@ -1,5 +1,9 @@
 Revision history for Perl extension JSON.
 
+4.01 2019-01-21
+    - added boolean function/method that takes a scalar value and
+      returns a boolean value (David Cantrell)
+
 4.00 2018-12-07
     - production release
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/JSON-4.00/META.json new/JSON-4.01/META.json
--- old/JSON-4.00/META.json     2018-12-06 18:32:04.000000000 +0100
+++ new/JSON-4.01/META.json     2019-01-20 16:42:07.000000000 +0100
@@ -48,6 +48,6 @@
          "url" : "https://github.com/makamaka/JSON";
       }
    },
-   "version" : "4.00",
-   "x_serialization_backend" : "JSON version 4.00"
+   "version" : "4.01",
+   "x_serialization_backend" : "JSON version 4.01"
 }
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/JSON-4.00/META.yml new/JSON-4.01/META.yml
--- old/JSON-4.00/META.yml      2018-12-06 18:32:04.000000000 +0100
+++ new/JSON-4.01/META.yml      2019-01-20 16:42:07.000000000 +0100
@@ -24,5 +24,5 @@
 resources:
   bugtracker: https://github.com/makamaka/JSON/issues
   repository: https://github.com/makamaka/JSON
-version: '4.00'
+version: '4.01'
 x_serialization_backend: 'CPAN::Meta::YAML version 0.012'
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/JSON-4.00/lib/JSON.pm new/JSON-4.01/lib/JSON.pm
--- old/JSON-4.00/lib/JSON.pm   2018-12-06 18:30:06.000000000 +0100
+++ new/JSON-4.01/lib/JSON.pm   2019-01-20 16:41:59.000000000 +0100
@@ -9,7 +9,7 @@
 @JSON::EXPORT = qw(from_json to_json jsonToObj objToJson encode_json 
decode_json);
 
 BEGIN {
-    $JSON::VERSION = '4.00';
+    $JSON::VERSION = '4.01';
     $JSON::DEBUG   = 0 unless (defined $JSON::DEBUG);
     $JSON::DEBUG   = $ENV{ PERL_JSON_DEBUG } if exists $ENV{ PERL_JSON_DEBUG };
 }
@@ -196,6 +196,11 @@
 
 sub false { $JSON::false }
 
+sub boolean {
+    # might be called as method or as function, so pop() to get the last arg 
instead of shift() to get the first
+    pop() ? $JSON::true : $JSON::false
+}
+
 sub null  { undef; }
 
 
@@ -473,7 +478,7 @@
 
 =head1 VERSION
 
-    4.00
+    4.01
 
 =head1 DESCRIPTION
 
@@ -1254,6 +1259,13 @@
 
 You can use this to get/set a value of a particular flag.
 
+=head2 boolean
+
+    $boolean_object = JSON->boolean($scalar)
+
+Returns $JSON::true if $scalar contains a true value, $JSON::false otherwise.
+You can use this as a full-qualified function (C<JSON::boolean($scalar)>).
+
 =head1 INCREMENTAL PARSING
 
 This section is also taken from JSON::XS.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/JSON-4.00/t/118_boolean_values.t 
new/JSON-4.01/t/118_boolean_values.t
--- old/JSON-4.00/t/118_boolean_values.t        2018-12-06 18:29:06.000000000 
+0100
+++ new/JSON-4.01/t/118_boolean_values.t        2019-01-16 18:21:24.000000000 
+0100
@@ -28,6 +28,8 @@
 }
 if (eval "require JSON; 1") {
     push @tests, [JSON::true(), JSON::false(), 'JSON::PP::Boolean', 
'JSON::PP::Boolean'];
+    push @tests, [JSON->boolean(11), JSON->boolean(undef), 
'JSON::PP::Boolean', 'JSON::PP::Boolean'];
+    push @tests, [JSON::boolean(11), JSON::boolean(undef), 
'JSON::PP::Boolean', 'JSON::PP::Boolean'];
 }
 if (eval "require Data::Bool; 1") {
     push @tests, [Data::Bool::true(), Data::Bool::false(), 'Data::Bool::Impl', 
'Data::Bool::Impl'];


Reply via email to