Skip Menu |

This queue is for tickets about the Sort-Versions CPAN distribution.

Report information
The Basics
Id: 128545
Status: new
Priority: 0/
Queue: Sort-Versions

Owner: Nobody in particular
Requestors: leonerd-cpan [...]

Bug Information
Severity: (no value)
Broken in: 1.62
Fixed in: (no value)

Subject: Confused by leading zeroes
MIME-Version: 1.0
X-Mailer: MIME-tools 5.504 (Entity 5.504)
Content-Disposition: inline
X-RT-Interface: Web
Message-ID: <rt-4.0.18-15140-1550441242-107.0-0-0 [...]>
Content-Type: text/plain; charset="utf-8"
Content-Transfer-Encoding: binary
X-RT-Original-Encoding: utf-8
X-RT-Encrypt: 0
X-RT-Sign: 0
Content-Length: 526
Download (untitled) / with headers
text/plain 526b
Although it doesn't outright state so, the docs imply that in groups of pure digits, that leading zeroes ought to be ignored. The docs state: If digit groups are being compared on both sides, a numeric comparison is used So we ought to expect that "2.0.0" and "2.000.0", say, compare equal. But yet: $ perl -MSort::Versions -E'say "OK" if versioncmp("2.0.0", "2.0.0") == 0' OK $ perl -MSort::Versions -E'say "OK" if versioncmp("2.0.0", "2.000.0") == 0' (no output) $ perlmodversion Sort::Versions 1.62 -- Paul Evans

This service is sponsored and maintained by Best Practical Solutions and runs on infrastructure.

Please report any issues with to