22/06/06, Joshua ben Jore <twists (AT) gmail (DOT) comwrote:
6/21/06, John Peacock <jpeacock (AT) rowman (DOT) comwrote:
Joshua ben Jore wrote:
josh@lik:~$ bin/perl/5.9.4/bin/perl5.9.4 -Mwarnings -e '$^V ge "\5\x08\0"'
Useless use of string ge in void context at -e line 1.
Version string ' contains invalid data; ignoring: ' at -e line 1.
I'm kind of stuck here. There is no way for me to know that you have hand
crafted what is equivalent to a v-string without using the magic v-string code
(found in 5.8.1 or better):
You're stuck?! The docs say I'm supposed to make a string equivalent
to C<chr(5) . chr(8) . chr(0)>!
But you still have that string. You only have a bit of V magic in it.
If you use a version string the comparison works.
the other hand, $^V is not a plain scalar, it's an object, and it
doesn't stringify to a string of non printable chars.
I'm not sure adding heuristics to scan_version would be a good idea,
that might introduce inconsistencies and puzzle users.
That's the "old" current docs starting
at 5.6.0 and the stuff that's still in the "new" current docs still in
my synched up bleadperl. I figured the documentation was promising
that this would work and be more backwards compatible than using the
v5.8.0 syntax.
Which docs need an update?