File: json-pp-warnings.diff

package info (click to toggle)
perl 5.36.0-7%2Bdeb12u3
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 120,064 kB
  • sloc: ansic: 650,199; perl: 478,052; sh: 70,710; pascal: 8,435; xml: 2,428; yacc: 1,230; makefile: 1,175; cpp: 208; lisp: 1
file content (26 lines) | stat: -rw-r--r-- 921 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
From: Kenichi Ishigaki <ishigaki@cpan.org>
Date: Sun, 9 Oct 2022 08:41:56 +0900
Subject: Call unimport first to silence warnings

Trivially backported to JSON-PP 4.07 (as shipped with Perl 5.36)
by Niko Tyni <ntyni@debian.org>

Bug-Debian: https://bugs.debian.org/1019757
Bug: https://github.com/makamaka/JSON-PP/issues/76
Origin: backport, https://github.com/makamaka/JSON-PP/pull/79
---
 cpan/JSON-PP/lib/JSON/PP/Boolean.pm | 1 +
 1 file changed, 1 insertion(+)

diff --git a/cpan/JSON-PP/lib/JSON/PP/Boolean.pm b/cpan/JSON-PP/lib/JSON/PP/Boolean.pm
index d1ee0a4..073da7b 100644
--- a/cpan/JSON-PP/lib/JSON/PP/Boolean.pm
+++ b/cpan/JSON-PP/lib/JSON/PP/Boolean.pm
@@ -3,6 +3,7 @@ package JSON::PP::Boolean;
 use strict;
 require overload;
 local $^W;
+overload::unimport('overload', qw(0+ ++ -- fallback));
 overload::import('overload',
     "0+"     => sub { ${$_[0]} },
     "++"     => sub { $_[0] = ${$_[0]} + 1 },