----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/64754/#review194277 -----------------------------------------------------------
3rdparty/stout/include/stout/bytes.hpp Lines 82-85 (original), 82-85 (patched) <https://reviews.apache.org/r/64754/#comment273005> I'm not so sure we need these at all, is it possible to remove them? Doubles are a little concerning, since there is a base unit of bytes involved here but doubles can represent values smaller than a single byte? E.g. 1.0000000001 kilobytes - Benjamin Mahler On Dec. 20, 2017, 10:13 p.m., Chun-Hung Hsiao wrote: > > ----------------------------------------------------------- > This is an automatically generated e-mail. To reply, visit: > https://reviews.apache.org/r/64754/ > ----------------------------------------------------------- > > (Updated Dec. 20, 2017, 10:13 p.m.) > > > Review request for mesos, Benjamin Bannier, Benjamin Mahler, Jie Yu, and > Vinod Kone. > > > Repository: mesos > > > Description > ------- > > This patch makes `kilobytes()`, `megabytes()`, `gigabytes()` and > `terabytes()` return doubles to keep the precisions. > > NOTE: In the Mesos codebase, the returned values of these helper > functions except for the ones in the tests and SLRPs are used in the > following 3 ways: > > 1. Comparing with some constant value. > 2. Stringified as part of a log message. > 3. Stringified then onsumed by `Resources::parse()`, which will do fixed > point normalization. > > In all cases, the changes introduced in this patch should make no harm, > but just make the result more accurate. > > > Diffs > ----- > > 3rdparty/stout/include/stout/bytes.hpp > cbe953662bb86c2f1eef3453f557ea17c0c6d13e > > > Diff: https://reviews.apache.org/r/64754/diff/1/ > > > Testing > ------- > > See later in chain. > > > Thanks, > > Chun-Hung Hsiao > >
