@@ -2,14 +2,8 @@ package version::regex;
22
33use strict;
44
5- use vars qw(
6- $VERSION $CLASS $STRICT $LAX
7- $STRICT_DECIMAL_VERSION $STRICT_DOTTED_DECIMAL_VERSION
8- $LAX_DECIMAL_VERSION $LAX_DOTTED_DECIMAL_VERSION
9- ) ;
10-
11- $VERSION = ' 0.9918_02c' ;
12- $VERSION =~ s / c$// ;
5+ our $VERSION = ' 0.9923_02' ;
6+ # $VERSION =~ s/c$//;
137
148# --------------------------------------------------------------------------#
159# Version regexp components
@@ -63,19 +57,19 @@ my $LAX_ALPHA_PART = qr/(?:_[0-9]+c?|c?)/;
6357
6458# Strict decimal version number.
6559
66- $STRICT_DECIMAL_VERSION =
60+ our $STRICT_DECIMAL_VERSION =
6761 qr / $STRICT_INTEGER_PART $FRACTION_PART ? c? / x ;
6862
6963# Strict dotted-decimal version number. Must have both leading "v" and
7064# at least three parts, to avoid confusion with decimal syntax.
7165
72- $STRICT_DOTTED_DECIMAL_VERSION =
66+ our $STRICT_DOTTED_DECIMAL_VERSION =
7367 qr / v $STRICT_INTEGER_PART $STRICT_DOTTED_DECIMAL_PART {2,} c? / x ;
7468
7569# Complete strict version number syntax -- should generally be used
7670# anchored: qr/ \A $STRICT \z /x
7771
78- $STRICT =
72+ our $STRICT =
7973 qr / $STRICT_DECIMAL_VERSION | $STRICT_DOTTED_DECIMAL_VERSION / x ;
8074
8175# --------------------------------------------------------------------------#
@@ -86,7 +80,7 @@ $STRICT =
8680# allowing an alpha suffix or allowing a leading or trailing
8781# decimal-point
8882
89- $LAX_DECIMAL_VERSION =
83+ our $LAX_DECIMAL_VERSION =
9084 qr / $LAX_INTEGER_PART (?: $FRACTION_PART | \. )? $LAX_ALPHA_PART ?
9185 |
9286 $FRACTION_PART $LAX_ALPHA_PART ?
@@ -98,7 +92,7 @@ $LAX_DECIMAL_VERSION =
9892# enough, without the leading "v", Perl takes .1.2 to mean v0.1.2,
9993# so when there is no "v", the leading part is optional
10094
101- $LAX_DOTTED_DECIMAL_VERSION =
95+ our $LAX_DOTTED_DECIMAL_VERSION =
10296 qr /
10397 v $LAX_INTEGER_PART (?: $LAX_DOTTED_DECIMAL_PART + $LAX_ALPHA_PART ? )?
10498 |
@@ -111,7 +105,7 @@ $LAX_DOTTED_DECIMAL_VERSION =
111105# The string 'undef' is a special case to make for easier handling
112106# of return values from ExtUtils::MM->parse_version
113107
114- $LAX =
108+ our $LAX =
115109 qr / undef | $LAX_DOTTED_DECIMAL_VERSION | $LAX_DECIMAL_VERSION / x ;
116110
117111# --------------------------------------------------------------------------#
0 commit comments