summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--handy.h5
1 files changed, 3 insertions, 2 deletions
diff --git a/handy.h b/handy.h
index 53477994a3..f75c900656 100644
--- a/handy.h
+++ b/handy.h
@@ -260,8 +260,9 @@ typedef U64TYPE U64;
#endif
-/* log(2) is pretty close to 0.30103, just in case anyone is grepping for it */
-#define BIT_DIGITS(N) (((N)*146)/485 + 1) /* log2(10) =~ 146/485 */
+/* log(2) (i.e., log base 10 of 2) is pretty close to 0.30103, just in case
+ * anyone is grepping for it */
+#define BIT_DIGITS(N) (((N)*146)/485 + 1) /* log10(2) =~ 146/485 */
#define TYPE_DIGITS(T) BIT_DIGITS(sizeof(T) * 8)
#define TYPE_CHARS(T) (TYPE_DIGITS(T) + 2) /* sign, NUL */