Reported Module::Metadata's issue.

https://rt.cpan.org/Ticket/Display.html?id=90783&results=7e009dacbb4df99bf099bb18ddee5af5

Following test code fails with latest M::Metadata.

use strict;
use warnings;
use Test::More tests => 1;

use Module::Metadata;

note "VERSION: $Module::Metadata::VERSION\n";

my $info = Module::Metadata->new_from_handle(*DATA, 'foo.pm');
is $info->version, '0.01';

__DATA__
package foo;

<<'...';
our \$VERSION = '$Mouse::Spec::VERSION';
...

our $VERSION = "0.01";

1;

The output is:

1..1
# VERSION: 1.000019
Error evaling version line 'BEGIN { my $dummy = q#  Hide from _packages_inside()
    #; package Module::Metadata::_version::p1;
    use version;
    no strict;
    no warnings;

    $vsub = sub {
        local $VERSION;
        $VERSION=undef;
        our \$VERSION = '$Mouse::Spec::VERSION';;
        $VERSION
    };
}' in /home/tokuhirom/tmp/20131125/foo.pm: syntax error at (eval 11) line 10, near "our \"
BEGIN not safe after errors--compilation aborted at (eval 11) line 13, <DATA> line 4.

failed to build version sub for /home/tokuhirom/tmp/20131125/foo.pm at hoge.pl line 9.
# Looks like your test exited with 255 before it could output anything.

Published: 2013-12-13(Fri) 12:42