bytesize icon indicating copy to clipboard operation
bytesize copied to clipboard

Utilize `#` specifier to implement `Display` trait for SI unit

Open EFanZh opened this issue 4 years ago • 3 comments

So that it is possible to use {} for decimal units (KB, MB, GB), and {:#} for binary units (KiB, MiB, GiB).

EFanZh avatar Apr 11 '21 06:04 EFanZh

This seems rather ad-hoc to me. I would prefer explicitly naming the unit rather than having this be done ad-hoc with formatting specifiers.

wookietreiber avatar Apr 15 '21 07:04 wookietreiber

KB by default looks strange to me. Never have I met a programmer thinking in decimal units instead of binary units.

loyd avatar Apr 18 '23 11:04 loyd