Subject: | MX:M:S can corrupt line numbers for unrelated parts of the file |
$ cat lineno
#!perl
use warnings;
use strict;
use MooseX::Method::Signatures;
{
my $uniq = 0;
method fresh_name() {
$self->prefix . $uniq++
}
} # this is line 13
method prefix() {
$self->{prefix}
}
my $aref = [];
my $oops = %{ $aref };
print "got $oops\n";
__END__
$ perl lineno
Not a HASH reference at lineno line 13.
This line number is bogus. Line 13 is "}"; the actual error is on line
20. Corrupted line numbers make debugging runtime errors unnecessarily
interesting.