Subject: | [PATCH] Moose Class::MOP::load_class Deprecation Warnings |
Hey,
Attached patch fixes the warnings produced by the deprecation of Class::MOP::load_class. Below is a blurb the Moose guys have been distributing.
---
We recently deprecated Class::MOP::load_class in Moose. It appears that your module is affected. You can read more about the change here: https://metacpan.org/pod/release/ETHER/Moose-2.1106-TRIAL/lib/Moose/Manual/Delta.pod#pod2.1200 We recommend that you take a look at your code to see if it indeed does need to be updated with respect to the latest Moose release, 2.1106-TRIAL. If you have any questions, then please ask either on Moose mailing list : http://lists.perl.org/list/moose.html or on #moose & #moose-dev on irc.perl.org.
--
Cheers,
ZZ [ https://metacpan.org/author/ZOFFIX ]
Subject: | RDF-Helper-2.0.patch |
diff -Naur RDF-Helper-2.0_orig/dist.ini RDF-Helper-2.0/dist.ini
--- RDF-Helper-2.0_orig/dist.ini 2014-01-24 22:43:11.370618214 -0500
+++ RDF-Helper-2.0/dist.ini 2014-01-24 22:46:05.482620495 -0500
@@ -16,6 +16,7 @@
URI = 0
Moose = 1.09
MooseX::Aliases = 0
+Class::Load = 0.20
diff -Naur RDF-Helper-2.0_orig/lib/RDF/Helper/API.pm RDF-Helper-2.0/lib/RDF/Helper/API.pm
--- RDF-Helper-2.0_orig/lib/RDF/Helper/API.pm 2014-01-24 22:43:11.366618214 -0500
+++ RDF-Helper-2.0/lib/RDF/Helper/API.pm 2014-01-24 22:43:34.078618510 -0500
@@ -1,6 +1,6 @@
package RDF::Helper::API;
+use Class::Load;
use Moose::Role;
-
requires qw(
arrayref2rdf
assert_literal
@@ -87,7 +87,7 @@
my ( $query_string, $query_lang ) = @_;
my $class = $self->query_interface;
- Class::MOP::load_class($class);
+ Class::Load::load_class($class);
return $class->new( $query_string, $query_lang, $self->model );
}
diff -Naur RDF-Helper-2.0_orig/lib/RDF/Helper.pm RDF-Helper-2.0/lib/RDF/Helper.pm
--- RDF-Helper-2.0_orig/lib/RDF/Helper.pm 2014-01-24 22:43:11.370618214 -0500
+++ RDF-Helper-2.0/lib/RDF/Helper.pm 2014-01-24 22:45:54.342620348 -0500
@@ -5,6 +5,7 @@
use RDF::Helper::Statement;
use RDF::Helper::Object;
+use Class::Load;
has backend => (
does => 'RDF::Helper::API',
@@ -31,7 +32,7 @@
default { $class = 'RDF::Helper::RDFTrine' }
}
- Class::MOP::load_class($class);
+ Class::Load::load_class($class);
my $backend = $class->new(%$args);
return { backend => $backend };
}