kjolley / BIGSdb

Bacterial Isolate Genome Sequence Database (BIGSdb): A platform for gene-by-gene bacterial population annotation and analysis.

Home Page:https://pubmlst.org/software/bigsdb/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Suggestion on round and lround module of POSIX

abrozzi opened this issue · comments

Dear Keith,

I noticed that POSIX module triggers some conflicts with perl versioning (5.16 versus newer).
Since lround is only used once in /lib/BIGSdb/Plugins/SeqbinBreakdown.pm I would humbly suggest to replace it with something simple but effective like:

sub round {
    my ($number) = @_;
    return int($number + 0.5 * ($number <=> 0));
}

HTH
-A

Hi Alessandro,

This seems sensible and a good solution. Thanks.