Skip Menu |

This queue is for tickets about the JSON CPAN distribution.

Report information
The Basics
Id: 106994
Status: resolved
Priority: 0/
Queue: JSON

People
Owner: Nobody in particular
Requestors: brianski [...] cpan.org
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: 2.53
Fixed in: 2.90



JSON and JSON::PP do not honor each other's constants for true and false. Ideally we'd use only one or the other implementation and that would be that, but in legacy code that is not always an option: $ perl -le 'use strict; use JSON; use JSON::PP; my $json = { true => JSON::PP::true, false => JSON::PP::false }; print JSON->new()->allow_blessed(1)->convert_blessed(1)->encode( $json ); ' Prototype mismatch: sub main::decode_json ($) vs none at /home/ski/perl5/lib/5.14.2/Exporter.pm line 67. at -e line 1 Prototype mismatch: sub main::from_json ($@) vs ($) at /home/ski/perl5/lib/5.14.2/Exporter.pm line 67. at -e line 1 Prototype mismatch: sub main::to_json ($@) vs ($) at /home/ski/perl5/lib/5.14.2/Exporter.pm line 67. at -e line 1 {"false":null,"true":null} $ perl -le 'use strict; use warnings; use JSON; use JSON::PP; my $json = { true => JSON::true, false => JSON::false }; print JSON::PP->new()->allow_blessed(1)->convert_blessed(1)->encode( $json ); ' Prototype mismatch: sub main::decode_json ($) vs none at /home/ski/perl5/lib/5.14.2/Exporter.pm line 67. at -e line 1 Prototype mismatch: sub main::from_json ($@) vs ($) at /home/ski/perl5/lib/5.14.2/Exporter.pm line 67. at -e line 1 Prototype mismatch: sub main::to_json ($@) vs ($) at /home/ski/perl5/lib/5.14.2/Exporter.pm line 67. at -e line 1 {"false":null,"true":null}
Sorry, you can ignore this. I was using 2.34, but it seems fixed in 2.90.
On Thu Sep 10 08:01:08 2015, BRIANSKI wrote: Show quoted text
> Sorry, you can ignore this. I was using 2.34, but it seems fixed in 2.90.
Closed.