mesos-reviews mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Andrew Schwartzmeyer <>
Subject Re: Review Request 59865: Fixed conversion warning in `duration.hpp`.
Date Wed, 07 Jun 2017 20:00:56 GMT

This is an automatically generated e-mail. To reply, visit:

(Updated June 7, 2017, 8 p.m.)

Review request for mesos, Jeff Coffler, John Kordich, Joseph Wu, and Li Li.


Fixed to use `decltype`.

Bugs: MESOS-7459

Repository: mesos

Description (updated)

While `ns()` and our other types are `int64_t`, the variables to which
we're assigning are (by definition of `struct timeval`) a `time_t` or a
`long` (depending on platform). We cast it because there is no
alternative, and we otherwise generate hundreds of warnings. We cast to
`decltype(...)` because the type is different depending on platform.

Diffs (updated)

  3rdparty/stout/include/stout/duration.hpp 138993e25c51efc82d447fe82037bf3a5fe7fd91 




Built `stout-tests` on Windows and Linux, no more `duration.hpp` warnings.


Andrew Schwartzmeyer

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message