> On March 5, 2019, 11:09 p.m., Benjamin Bannier wrote: > > 3rdparty/stout/include/stout/result.hpp > > Line 126 (original), 140 (patched) > > > > > > The `mesos-redundant-get` clang-tidy check will incorrectly suggest to use `std::forward(self).data->get()` here which I am not sure how to fix (this function will work on both rvalue and lvalue `self` values which AFAICT don't propagate the same way through `operator->`. > > > > I'd suggest we add a linter suppression here for now until we possibly get rid of `get` in favor of `operator*` for good. > > ``` > > return std::forward(self) > > .data > > .get() // NOLINT(mesos-redundant-get) > > .get(); > > ``` Actually there's also `NOLINTNEXTLINT` which would allow us to keep the expression on a single line, e.g., ``` // NOTLINENEXTLINE(mesos-redundant-get) return std::forward(self).data.get().get() ``` Also above. - Benjamin ----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/70123/#review213433 ----------------------------------------------------------- On March 5, 2019, 12:53 a.m., Meng Zhu wrote: > > ----------------------------------------------------------- > This is an automatically generated e-mail. To reply, visit: > https://reviews.apache.org/r/70123/ > ----------------------------------------------------------- > > (Updated March 5, 2019, 12:53 a.m.) > > > Review request for mesos, Benjamin Bannier and Benjamin Mahler. > > > Repository: mesos > > > Description > ------- > > Added rvalue overload for `Result::get()`. > > > Diffs > ----- > > 3rdparty/stout/include/stout/result.hpp c1387ae957edffc31250b9b236b5f1fd8ff0acd3 > > > Diff: https://reviews.apache.org/r/70123/diff/2/ > > > Testing > ------- > > make check > > > Thanks, > > Meng Zhu > >