diff options
Diffstat (limited to 'Master/tlpkg/tlperl/lib/JSON/PP/Boolean.pm')
-rw-r--r-- | Master/tlpkg/tlperl/lib/JSON/PP/Boolean.pm | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/Master/tlpkg/tlperl/lib/JSON/PP/Boolean.pm b/Master/tlpkg/tlperl/lib/JSON/PP/Boolean.pm index 1d1c5c485cc..8b98c95c2f4 100644 --- a/Master/tlpkg/tlperl/lib/JSON/PP/Boolean.pm +++ b/Master/tlpkg/tlperl/lib/JSON/PP/Boolean.pm @@ -1,14 +1,16 @@ package JSON::PP::Boolean; use strict; -use overload ( +require overload; +local $^W; +overload::import('overload', "0+" => sub { ${$_[0]} }, "++" => sub { $_[0] = ${$_[0]} + 1 }, "--" => sub { $_[0] = ${$_[0]} - 1 }, fallback => 1, ); -$JSON::PP::Boolean::VERSION = '2.97001'; +$JSON::PP::Boolean::VERSION = '4.02'; 1; @@ -31,5 +33,10 @@ L<JSON::PP> for more info about this class. This idea is from L<JSON::XS::Boolean> written by Marc Lehmann <schmorp[at]schmorp.de> +=head1 LICENSE + +This library is free software; you can redistribute it and/or modify +it under the same terms as Perl itself. + =cut |