Subject: | I detected a problem in ExtUtils::MakeMakers created MAKEFILE. |
Think about this:
In module:
# gets a version from CVS
our $VERSION = eval 'v'.qw($Revision: 1.10 $)[1];
In Script or module:
use Module v1.10; # creates a compile time error
# v1.9 is less then v1.10.
The problem is:
The MAKEFILE includes VERSION= and then 2 binary chars. Often it isnt really bad. But in Version v1.36 the chars are \1 followed by $ and make creates an error.
But
MG_TYPE = ... (V)
and
MG_PTR = ... "v1.36"
show you that $VERSION is not really a String or Number. Typical Perl version check converts v1.36 to 1.036 to compare it with a number.
I show you the dumped $VERSION created by Devel::Peek.
SV = PVMG(0x19df07c) at 0x22616c
REFCNT = 1
FLAGS = (PADBUSY,PADTMP,RMG,POK,READONLY,pPOK)
IV = 0
NV = 0
PV = 0x183319c "\1$"\0
CUR = 2
LEN = 6
MAGIC = 0x1c9535c
MG_VIRTUAL = 0
MG_TYPE = PERL_MAGIC_v-string(V)
MG_LEN = 5
MG_PTR = 0x182a5c4 "v1.36"