Subject: | Setting ${^ENCODING} is now deprecated |
Setting this variable is now deprecated and it is planned to remove it from a future Perl version. The attached patch just turns off the message for now.
I'm not sure what the long term approach should be for this module. All of 'use encoding' is deprecated, and we plan to get rid of it as soon as we can get all the CPAN modules that use it to stop doing so. The advice in the pod of this module to use that pragma is hence now ill advised. People should be storing their files as UTF-8, and saying 'use utf8'.
Subject: | 0001-Turn-off-deprecated-warning-msg.patch |
From 21aa29e4f3cc207fd6497072c70b3056270a69eb Mon Sep 17 00:00:00 2001
From: Karl Williamson <khw@cpan.org>
Date: Mon, 24 Nov 2014 15:07:00 -0700
Subject: [PATCH] Turn off deprecated warning msg
---
cpan/encoding-warnings/lib/encoding/warnings.pm | 2 ++
1 file changed, 2 insertions(+)
diff --git a/cpan/encoding-warnings/lib/encoding/warnings.pm b/cpan/encoding-warnings/lib/encoding/warnings.pm
index 5e6aec0..5295d52 100644
--- a/cpan/encoding-warnings/lib/encoding/warnings.pm
+++ b/cpan/encoding-warnings/lib/encoding/warnings.pm
@@ -170,7 +170,9 @@ sub import {
], $class,
);
+ no warnings 'deprecated';
${^ENCODING} = $decoder;
+ use warnings 'deprecated';
$^H{$class} = 1;
}
--
1.9.1