diff options
author | hut <hut@lavabit.com> | 2012-03-14 17:17:32 +0100 |
---|---|---|
committer | hut <hut@lavabit.com> | 2012-03-14 17:17:32 +0100 |
commit | 6458c26c954e13be51c2e2a9b3cbe1d92cde55e0 (patch) | |
tree | e19b6b98ee54a442fc872dacb9a4f2bf77d805d0 | |
parent | 8a81af124633a65c2bbe12a7755cb982738790cd (diff) | |
download | ranger-6458c26c954e13be51c2e2a9b3cbe1d92cde55e0.tar.gz |
ext.human_readable: added comment
-rw-r--r-- | ranger/ext/human_readable.py | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/ranger/ext/human_readable.py b/ranger/ext/human_readable.py index a3aed1bb..9667421a 100644 --- a/ranger/ext/human_readable.py +++ b/ranger/ext/human_readable.py @@ -12,6 +12,10 @@ def human_readable(byte, separator=' '): >>> human_readable(2 ** 20 * 1023) '1023 M' """ + + # I know this can be written much shorter, but this long version + # performs much better than what I had before. If you attempt to + # shorten this code, take performance into consideration. if byte <= 0: return '0' if byte < 2**10: |