dagolden / Path-Tiny

File path utility
41 stars 59 forks source link

Why not using POSIX::ceil instead of your own custom _ceil() function? #245

Closed robrwo closed 2 years ago

robrwo commented 2 years ago

POSIX is a core module. Why not just use POSIX::ceil instead of creating your own _ceil function

xdg commented 2 years ago

Loading POSIX increases Path::Tiny's memory footprint by 10%. Seemed unnecessary for what is likely to be a rarely used method. Path::Tiny doesn't universally optimize for performance -- only around the hottest part of the code, like path manipulation and slurping/spewing.

robrwo commented 2 years ago

Fair enough. Might be worth adding a one-line comment about that.