From: Florian Ragwitz Date: Fri, 20 Feb 2009 17:25:38 +0000 (+0000) Subject: Unbreak disabling of NEXT warnings on non-dev releases. X-Git-Tag: 5.80001~72 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?p=catagits%2FCatalyst-Runtime.git;a=commitdiff_plain;h=4ed63588abf17920cdf7ba9b4a1f3f9893064e6a Unbreak disabling of NEXT warnings on non-dev releases. --- diff --git a/lib/Catalyst.pm b/lib/Catalyst.pm index 278a2f5..1fbccdd 100644 --- a/lib/Catalyst.pm +++ b/lib/Catalyst.pm @@ -77,6 +77,12 @@ __PACKAGE__->stats_class('Catalyst::Stats'); # Remember to update this in Catalyst::Runtime as well! our $VERSION = '5.8000_06'; + +{ + my $dev_version = $VERSION =~ /_\d{2}$/; + *_IS_DEVELOPMENT_VERSION = sub () { $dev_version }; +} + $VERSION = eval $VERSION; sub import { @@ -90,7 +96,7 @@ sub import { return if $caller eq 'main'; # Kill Adopt::NEXT warnings if we're a non-RC version - if ($VERSION !~ /_\d{2}$/) { + unless (_IS_DEVELOPMENT_VERSION()) { Class::C3::Adopt::NEXT->unimport(qr/^Catalyst::/); }