Subject: | Bug in Regexp::Common::number? |
Date: | Wed, 13 Jan 2016 10:23:54 -0500 |
To: | bug-Regexp-Common [...] rt.cpan.org |
From: | Bob Wetmore <whataboutbobw [...] gmail.com> |
This is perl 5, version 18, subversion 2 (v5.18.2) built for
x86_64-linux-gnu-thread-multi
(with 41 registered patches, see perl -V for more detail)
$ uname -a
Linux bob-B654 3.13.0-74-generic #118-Ubuntu SMP Thu Dec 17 22:52:10 UTC
2015 x86_64 x86_64 x86_64 GNU/Linux
---------------------code---------------------------------
#!/usr/bin/perl -w
use 5.018;
use Regexp::Common qw(number);
my $string = "The integer is 1234567";
say "string is: $string";
if ( $string =~ /$RE{num}{int}{-sep=>',?'}{-keep}/ ) {
print "Matched: |$`<$&>$'|\n";
say "\$1 = $1";
}
Show quoted text
-----------------------output------------------------------
string is: The integer is 1234567
Matched: |The integer is <123456>7|
$1 = 123456
--------------------------------------------------------------------
Is this a bug?
Bob Wetmore
Arlington, VA