in reply to Module version checking flaw?
In case you also run into more complex version numbers like "v1.3a.4beta", you can get good results with:
- tyesub cmpVersions { my( $x, $y )= @_; for my $v ( $x, $y ) { $v =~ s/(\d+)/ pack "N", $1 /ge; } return $x cmp $y; }
In Section
Seekers of Perl Wisdom