mesos-reviews mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Michael Park <mp...@apache.org>
Subject Re: Review Request 59865: Fixed conversion warning in `duration.hpp`.
Date Wed, 07 Jun 2017 19:41:34 GMT

-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/59865/#review177211
-----------------------------------------------------------




3rdparty/stout/include/stout/duration.hpp
Lines 105-109 (patched)
<https://reviews.apache.org/r/59865/#comment250759>

    Maybe just do `t.tv_sec = static_cast<decltype(t.tv_sec)>(ns() / SECONDS);`?


- Michael Park


On June 6, 2017, 3:48 p.m., Andrew Schwartzmeyer wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/59865/
> -----------------------------------------------------------
> 
> (Updated June 6, 2017, 3:48 p.m.)
> 
> 
> Review request for mesos, Jeff Coffler, John Kordich, Joseph Wu, and Li Li.
> 
> 
> Bugs: MESOS-7459
>     https://issues.apache.org/jira/browse/MESOS-7459
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> While `ns()` and our other types are `int64_t`, the variable to which
> we're assigning is (by definition of `struct timeval`) a `long`. We cast
> it because there is no alternative, and we otherwise generate hundreds
> of warnings.
> 
> 
> Diffs
> -----
> 
>   3rdparty/stout/include/stout/duration.hpp 138993e25c51efc82d447fe82037bf3a5fe7fd91

> 
> 
> Diff: https://reviews.apache.org/r/59865/diff/1/
> 
> 
> Testing
> -------
> 
> Built `stout-tests` on Windows and Linux, no more `duration.hpp` warnings.
> 
> 
> Thanks,
> 
> Andrew Schwartzmeyer
> 
>


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