[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[lmi-commits] [lmi] master c17d68c 3/3: Improve documentation
From: |
Greg Chicares |
Subject: |
[lmi-commits] [lmi] master c17d68c 3/3: Improve documentation |
Date: |
Wed, 19 Apr 2017 09:53:40 -0400 (EDT) |
branch: master
commit c17d68caae7a891e5fabb08732e1ab0ee05d09aa
Author: Gregory W. Chicares <address@hidden>
Commit: Gregory W. Chicares <address@hidden>
Improve documentation
---
bourn_cast.hpp | 2 ++
1 file changed, 2 insertions(+)
diff --git a/bourn_cast.hpp b/bourn_cast.hpp
index c9c9ed5..1eb9fcf 100644
--- a/bourn_cast.hpp
+++ b/bourn_cast.hpp
@@ -130,6 +130,8 @@ inline To bourn_cast(From from, std::false_type,
std::true_type)
/// and the closest representable float is
/// 2^64 = 0x5F800000 = 01011111 10000000 00000000 00000000
/// [exponent: 01011111 (191 decimal) - 127 bias = 64]
+/// The integral type lacks the range to represent 2^64, while the
+/// floating type lacks the precision to represent 2^64 - 1.
/// Applying the usual arithmetic conversions to a comparison such as
/// if(ULLONG_MAX < float_argument) throw "out of range";
/// converts the integral maximum to the closest representable float,