Your code as presented will not work in versions prior to 5.6, because the $^V variable does not contain version information prior to 5.6. (See perl56delta).
To get at the version info in a portable way, you probably need to use the $] variable. See perlvar
In reply to Re: Formatting Perl's version numbers
by Joost
in thread Formatting Perl's version numbers
by jacques
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |