Subject: | Unexpected overload behavior on JSON |
Date: | Tue, 1 May 2012 12:18:06 +0900 |
To: | bug-JSON [...] rt.cpan.org |
From: | Tokuhiro Matsuno <tokuhirom [...] gmail.com> |
JSON.pm have a unexpected overloading behavior.
----- 8< --------- 8< --------- 8< --------- 8< --------- 8< --------- 8< --------- 8< --------- 8< ----
www4071uf% cat hoge.pl
use strict;
use warnings;
use utf8;
use 5.010000;
use JSON::XS;
use JSON ();
warn JSON::XS::true;
warn JSON::true;
www4071uf% perl hoge.pl
1 at hoge.pl line 9.
1 at hoge.pl line 10.
www4071uf% cat foo.pl
use strict;
use warnings;
use utf8;
use 5.010000;
use JSON ();
use JSON::XS;
warn JSON::XS::true;
warn JSON::true;
www4071uf% perl foo.pl
true at foo.pl line 9.
true at foo.pl line 10.
----- 8< --------- 8< --------- 8< --------- 8< --------- 8< --------- 8< --------- 8< --------- 8< ----
see http://d.hatena.ne.jp/tokuhirom/20120501/1335840913 for more details.
--
Tokuhiro Matsuno