This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
Update JSON-PP from 4.04 to 4.05
authorNicolas R <atoomic@cpan.org>
Wed, 8 Jul 2020 21:57:58 +0000 (15:57 -0600)
committerNicolas R <nicolas@atoomic.org>
Fri, 17 Jul 2020 21:33:30 +0000 (15:33 -0600)
44 files changed:
Porting/Maintainers.pl
cpan/JSON-PP/lib/JSON/PP.pm
cpan/JSON-PP/lib/JSON/PP/Boolean.pm
cpan/JSON-PP/t/000_load.t
cpan/JSON-PP/t/001_utf8.t
cpan/JSON-PP/t/002_error.t
cpan/JSON-PP/t/003_types.t
cpan/JSON-PP/t/004_dwiw_encode.t
cpan/JSON-PP/t/006_pc_pretty.t
cpan/JSON-PP/t/007_pc_esc.t
cpan/JSON-PP/t/008_pc_base.t
cpan/JSON-PP/t/009_pc_extra_number.t
cpan/JSON-PP/t/010_pc_keysort.t
cpan/JSON-PP/t/011_pc_expo.t
cpan/JSON-PP/t/012_blessed.t
cpan/JSON-PP/t/013_limit.t
cpan/JSON-PP/t/014_latin1.t
cpan/JSON-PP/t/015_prefix.t
cpan/JSON-PP/t/016_tied.t
cpan/JSON-PP/t/017_relaxed.t
cpan/JSON-PP/t/019_incr.t
cpan/JSON-PP/t/020_unknown.t
cpan/JSON-PP/t/021_evans.t
cpan/JSON-PP/t/052_object.t
cpan/JSON-PP/t/099_binary.t
cpan/JSON-PP/t/104_sortby.t
cpan/JSON-PP/t/105_esc_slash.t
cpan/JSON-PP/t/106_allow_barekey.t
cpan/JSON-PP/t/107_allow_singlequote.t
cpan/JSON-PP/t/108_decode.t
cpan/JSON-PP/t/109_encode.t
cpan/JSON-PP/t/110_bignum.t
cpan/JSON-PP/t/112_upgrade.t
cpan/JSON-PP/t/113_overloaded_eq.t
cpan/JSON-PP/t/114_decode_prefix.t
cpan/JSON-PP/t/115_tie_ixhash.t
cpan/JSON-PP/t/116_incr_parse_fixed.t
cpan/JSON-PP/t/117_numbers.t
cpan/JSON-PP/t/118_boolean_values.t
cpan/JSON-PP/t/gh_28_json_test_suite.t
cpan/JSON-PP/t/gh_29_trailing_false_value.t
cpan/JSON-PP/t/rt_116998_wrong_character_offset.t
cpan/JSON-PP/t/rt_90071_incr_parse.t
cpan/JSON-PP/t/zero-mojibake.t

index a44c108..5721b37 100755 (executable)
@@ -670,7 +670,7 @@ use File::Glob qw(:case);
     },
 
     'JSON::PP' => {
-        'DISTRIBUTION' => 'ISHIGAKI/JSON-PP-4.04.tar.gz',
+        'DISTRIBUTION' => 'ISHIGAKI/JSON-PP-4.05.tar.gz',
         'FILES'        => q[cpan/JSON-PP],
     },
 
index 9f08354..0507921 100644 (file)
@@ -14,7 +14,7 @@ use JSON::PP::Boolean;
 use Carp ();
 #use Devel::Peek;
 
-$JSON::PP::VERSION = '4.04';
+$JSON::PP::VERSION = '4.05';
 
 @JSON::PP::EXPORT = qw(encode_json decode_json from_json to_json);
 
@@ -1773,7 +1773,7 @@ JSON::PP - JSON::XS compatible pure-Perl module.
 
 =head1 VERSION
 
-    4.04
+    4.05
 
 =head1 DESCRIPTION
 
index 8ef6949..5d5b17c 100644 (file)
@@ -10,7 +10,7 @@ overload::import('overload',
     fallback => 1,
 );
 
-$JSON::PP::Boolean::VERSION = '4.04';
+$JSON::PP::Boolean::VERSION = '4.05';
 
 1;
 
index aa238dc..112b47b 100644 (file)
@@ -1,5 +1,9 @@
 # copied over from JSON::XS and modified to use JSON::PP
 
+use strict;
+use warnings;
+
+my $loaded;
 BEGIN { $| = 1; print "1..1\n"; }
 END {print "not ok 1\n" unless $loaded;}
 BEGIN { $ENV{PERL_JSON_BACKEND} = 0; }
index 95dff59..e160f82 100644 (file)
@@ -1,6 +1,7 @@
 # copied over from JSON::XS and modified to use JSON::PP
 
 use strict;
+use warnings;
 use Test::More;
 BEGIN { plan tests => 9 };
 
index 8d0765d..ae7b773 100644 (file)
@@ -1,6 +1,7 @@
 # copied over from JSON::XS and modified to use JSON::PP
 
 use strict;
+use warnings;
 use Test::More;
 BEGIN { plan tests => 35 };
 
index edf2990..11a73e2 100644 (file)
@@ -1,6 +1,7 @@
 # copied over from JSON::XS and modified to use JSON::PP
 
 use strict;
+use warnings;
 use Test::More;
 BEGIN { plan tests => 76 + 2 };
 
index a332947..32e4500 100644 (file)
@@ -6,6 +6,7 @@
 # Authors: don
 
 use strict;
+use warnings;
 use Test;
 
 # main
index 582f882..c8a5a0a 100644 (file)
@@ -2,6 +2,7 @@
 # copied over from JSON::XS and modified to use JSON::PP
 
 use strict;
+use warnings;
 use Test::More;
 BEGIN { plan tests => 9 };
 
@@ -10,7 +11,7 @@ BEGIN { $ENV{PERL_JSON_BACKEND} = 0; }
 use JSON::PP;
 
 my ($js,$obj,$json);
-my $pc = new JSON::PP;
+my $pc = JSON::PP->new;
 
 $obj = {foo => "bar"};
 $js = $pc->encode($obj);
index cbe6cd6..32fe808 100644 (file)
@@ -7,6 +7,7 @@
 
 use Test::More;
 use strict;
+use warnings;
 use utf8;
 BEGIN { plan tests => 17 };
 BEGIN { $ENV{PERL_JSON_BACKEND} = 0; }
@@ -16,7 +17,7 @@ use JSON::PP;
 #########################
 my ($js,$obj,$str);
 
-my $pc = new JSON::PP;
+my $pc = JSON::PP->new;
 
 $obj = {test => qq|abc"def|};
 $str = $pc->encode($obj);
index d8dc46d..762edfd 100644 (file)
@@ -4,6 +4,7 @@ use Test::More;
 # copied over from JSON::XS and modified to use JSON::PP
 
 use strict;
+use warnings;
 BEGIN { plan tests => 20 };
 BEGIN { $ENV{PERL_JSON_BACKEND} = 0; }
 
@@ -11,7 +12,7 @@ use JSON::PP;
 
 my ($js,$obj);
 
-my $pc = new JSON::PP;
+my $pc = JSON::PP->new;
 
 $js  = q|{}|;
 
index 1712064..d062f03 100644 (file)
@@ -3,6 +3,7 @@
 
 use Test::More;
 use strict;
+use warnings;
 BEGIN { plan tests => 6 };
 BEGIN { $ENV{PERL_JSON_BACKEND} = 0; }
 
@@ -11,7 +12,7 @@ use utf8;
 
 #########################
 my ($js,$obj);
-my $pc = new JSON::PP;
+my $pc = JSON::PP->new;
 
 $js  = '{"foo":0}';
 $obj = $pc->decode($js);
index cec6fe1..2dba569 100644 (file)
@@ -3,6 +3,7 @@
 
 use Test::More;
 use strict;
+use warnings;
 BEGIN { plan tests => 1 };
 BEGIN { $ENV{PERL_JSON_BACKEND} = 0; }
 
index 3167ef9..443b0d8 100644 (file)
@@ -3,6 +3,7 @@
 
 use Test::More;
 use strict;
+use warnings;
 BEGIN { plan tests => 8 + 2 };
 BEGIN { $ENV{PERL_JSON_BACKEND} = 0; }
 
@@ -10,7 +11,7 @@ use JSON::PP;
 
 #########################
 my ($js,$obj);
-my $pc = new JSON::PP;
+my $pc = JSON::PP->new;
 
 $js  = q|[-12.34]|;
 $obj = $pc->decode($js);
index 9329eb8..51f8558 100644 (file)
@@ -1,6 +1,7 @@
 # copied over from JSON::XS and modified to use JSON::PP
 
 use strict;
+use warnings;
 use Test::More;
 BEGIN { plan tests => 16 };
 
index 178a126..6aee693 100644 (file)
@@ -1,6 +1,7 @@
 # copied over from JSON::XS and modified to use JSON::PP
 
 use strict;
+use warnings;
 use Test::More;
 BEGIN { plan tests => 11 };
 
index 3069219..7030db8 100644 (file)
@@ -1,6 +1,7 @@
 # copied over from JSON::XS and modified to use JSON::PP
 
 use strict;
+use warnings;
 use Test::More;
 BEGIN { plan tests => 4 };
 
index d4e8b37..df4f1b8 100644 (file)
@@ -1,6 +1,7 @@
 # copied over from JSON::XS and modified to use JSON::PP
 
 use strict;
+use warnings;
 use Test::More;
 BEGIN { plan tests => 4 };
 
index 63d912e..0561397 100644 (file)
@@ -1,6 +1,7 @@
 # copied over from JSON::XS and modified to use JSON::PP
 
 use strict;
+use warnings;
 use Test::More;
 BEGIN { plan tests => 2 };
 
index 34fb60e..a49a3b4 100644 (file)
@@ -1,6 +1,7 @@
 # copied over from JSON::XS and modified to use JSON::PP
 
 use strict;
+use warnings;
 use Test::More;
 BEGIN { plan tests => 8 };
 
index 4e33982..e8d9c26 100644 (file)
@@ -45,7 +45,7 @@ splitter +JSON::PP->new                  , ' 0.00E+00 ';
 
 {
    my $text = '[5],{"":1} , [ 1,2, 3], {"3":null}';
-   my $coder = new JSON::PP;
+   my $coder = JSON::PP->new;
    for (0 .. length $text) {
       my $a = substr $text, 0, $_;
       my $b = substr $text, $_;
@@ -69,7 +69,7 @@ splitter +JSON::PP->new                  , ' 0.00E+00 ';
 
 {
    my $text = '[x][5]';
-   my $coder = new JSON::PP;
+   my $coder = JSON::PP->new;
    $coder->incr_parse ($text);
    ok (!eval { $coder->incr_parse }, "sparse1");
    ok (!eval { $coder->incr_parse }, "sparse2");
index 98e9528..6ab5b79 100644 (file)
@@ -1,11 +1,10 @@
 use strict;
+use warnings;
 
 use Test::More;
 BEGIN { plan tests => 10 };
 BEGIN { $ENV{PERL_JSON_BACKEND} = 0; }
 
-
-use strict;
 use JSON::PP;
 
 my $json = JSON::PP->new;
index 655f6fc..723d8e2 100644 (file)
@@ -14,7 +14,7 @@ print "1..1\n";
 my $data = ["\x{53f0}\x{6240}\x{306e}\x{6d41}\x{3057}",
             "\x{6c60}\x{306e}\x{30ab}\x{30a8}\x{30eb}"];
 my $js = JSON::PP->new->encode ($data);
-my $j = new JSON::PP;
+my $j = JSON::PP->new;
 my $object = $j->incr_parse ($js);
 
 die "no object" if !$object;
index 020db32..9b478f9 100644 (file)
@@ -1,6 +1,17 @@
 # copied over from JSON::XS and modified to use JSON::PP
 
+package JSON::PP::freeze;
+
+1;
+
+package JSON::PP::tojson;
+
+1;
+
+package main;
+
 use strict;
+use warnings;
 use Test::More;
 BEGIN { plan tests => 20 };
 BEGIN { $^W = 0 } # hate
@@ -47,8 +58,8 @@ sub JSON::PP::freeze::THAW {
    777
 }
 
-my $obj = bless { k => 1 }, JSON::PP::freeze::;
-my $enc = $json->encode ($obj);
+$obj = bless { k => 1 }, JSON::PP::freeze::;
+$enc = $json->encode ($obj);
 ok ($enc eq '("JSON::PP::freeze")[3,1,2]');
 
 my $dec = $json->decode ($enc);
index 2daa5b6..a1bce5d 100644 (file)
@@ -1,6 +1,7 @@
 # copied over from JSON::XS and modified to use JSON::PP
 
 use strict;
+use warnings;
 use Test::More;
 BEGIN { plan tests => 24576 };
 
index 649d7bd..1188e97 100644 (file)
@@ -1,6 +1,7 @@
 
 use Test::More;
 use strict;
+use warnings;
 BEGIN { plan tests => 3 };
 BEGIN { $ENV{PERL_JSON_BACKEND} = 0; }
 use JSON::PP;
index 225186b..56f415c 100644 (file)
@@ -1,6 +1,7 @@
 \r
 use Test::More;\r
-use strict;\r
+use strict;
+use warnings;\r
 BEGIN { plan tests => 2 };\r
 BEGIN { $ENV{PERL_JSON_BACKEND} = 0; }\r
 use JSON::PP;\r
index 85d3035..20918bb 100644 (file)
@@ -1,6 +1,7 @@
 \r
 use Test::More;\r
-use strict;\r
+use strict;
+use warnings;\r
 BEGIN { plan tests => 2 };\r
 BEGIN { $ENV{PERL_JSON_BACKEND} = 0; }\r
 use JSON::PP;\r
index 217caba..b3462f9 100644 (file)
@@ -1,6 +1,7 @@
 \r
 use Test::More;\r
-use strict;\r
+use strict;
+use warnings;\r
 BEGIN { plan tests => 4 };\r
 BEGIN { $ENV{PERL_JSON_BACKEND} = 0; }\r
 use JSON::PP;\r
index 438aeee..e0cec29 100644 (file)
@@ -2,6 +2,7 @@
 # decode on Perl 5.005, 5.6, 5.8 or later
 #
 use strict;
+use warnings;
 use Test::More;
 
 BEGIN { plan tests => 6 };
index ce7f510..95f7764 100644 (file)
@@ -2,6 +2,7 @@
 # decode on Perl 5.005, 5.6, 5.8 or later
 #
 use strict;
+use warnings;
 use Test::More;
 
 BEGIN { plan tests => 7 };
index c4c282f..99305dd 100644 (file)
@@ -1,5 +1,6 @@
 
 use strict;
+use warnings;
 use Test::More;
 BEGIN { plan tests => 9 };
 
@@ -20,7 +21,7 @@ my $fix =  !$v       ? '+'
           : '';
 
 
-my $json = new JSON::PP;
+my $json = JSON::PP->new;
 
 $json->allow_nonref->allow_bignum(1);
 $json->convert_blessed->allow_blessed;
index 1e319dc..853439a 100644 (file)
@@ -1,4 +1,5 @@
 use strict;
+use warnings;
 use Test::More;
 
 BEGIN { plan tests => 3 };
index 1b61c48..d4f7027 100644 (file)
@@ -1,4 +1,5 @@
 use strict;
+use warnings;
 use Test::More tests => 4;
 
 BEGIN {
@@ -26,6 +27,7 @@ ok(!$@);
 package Foo;
 
 use strict;
+use warnings;
 use overload (
     'eq' => sub { 0 },
     '""' => sub { $_[0] },
@@ -39,6 +41,7 @@ sub TO_JSON {
 package Bar;
 
 use strict;
+use warnings;
 use overload (
     'eq' => sub { 0 },
     '""' => sub { $_[0] },
index 10048d3..2b3dfa7 100644 (file)
@@ -1,4 +1,5 @@
 use strict;
+use warnings;
 use Test::More tests => 8;
 
 BEGIN {
index 51b3a4f..a8bed21 100644 (file)
@@ -1,5 +1,6 @@
 
 use strict;
+use warnings;
 use Test::More;
 BEGIN { plan tests => 2 };
 
index c00f023..6ad5d5c 100644 (file)
@@ -1,4 +1,5 @@
 use strict;
+use warnings;
 use Test::More tests => 4;
 
 use JSON::PP;
index a9d3df8..bd80f51 100644 (file)
@@ -1,5 +1,6 @@
 use Test::More;
 use strict;
+use warnings;
 BEGIN { $ENV{PERL_JSON_BACKEND} = 0; }
 BEGIN { $ENV{PERL_JSON_PP_USE_B} = 0 }
 use JSON::PP;
index 1a5d175..5a2c2b3 100644 (file)
@@ -1,4 +1,5 @@
 use strict;
+use warnings;
 use Test::More;
 BEGIN { $ENV{PERL_JSON_BACKEND} = 0; }
 use JSON::PP;
index be53660..ffbe294 100644 (file)
@@ -2,6 +2,7 @@
 # by Nicolas Seriot (https://github.com/nst/JSONTestSuite)
 
 use strict;
+use warnings;
 use Test::More;
 
 BEGIN { plan skip_all => 'this test is for Perl 5.8 or later' if $] < 5.008; }
index bb408e9..e569d29 100644 (file)
@@ -1,4 +1,5 @@
 use strict;
+use warnings;
 use Test::More;
 
 BEGIN { plan tests => 1 };
index b8f4707..e9b88c0 100644 (file)
@@ -1,4 +1,5 @@
 use strict;
+use warnings;
 use Test::More;
 BEGIN { plan tests => 4 };
 BEGIN { $ENV{PERL_JSON_BACKEND} = 0; }
index dc1fd45..cc07216 100644 (file)
@@ -1,4 +1,5 @@
 use strict;
+use warnings;
 use Test::More;
 BEGIN { $ENV{PERL_JSON_BACKEND} = 0; }
 use JSON::PP;
index 0ace370..8d5185d 100644 (file)
@@ -1,4 +1,5 @@
 use strict;
+use warnings;
 use Test::More;
 BEGIN { plan tests => 1 };