> On May 21, 2014, 10:22 a.m., Vinod Kone wrote:
> > 3rdparty/libprocess/3rdparty/stout/include/stout/os.hpp, line 678
> > <https://reviews.apache.org/r/21777/diff/1/?file=586696#file586696line678>
> >
> >     What is the exact warning that you are seeing in clang 3.4? Does it 
> > fail compilation?
> >     
> >     Also, would it be better to overload the copy constructor of Result for 
> > Unreachable?

This keeps the fix localised without risking any unexpected knock-ons for the 
rest of the code.


|| In file included from 
../../../../3rdparty/libprocess/3rdparty/stout/tests/os/signals_tests.cpp:8:
3rdparty/libprocess/3rdparty/stout/include/stout/os.hpp|677 col 10| error: 
conversion from 'Unreachable' to 'Result<uid_t>' is ambiguous
||   return UNREACHABLE();
||          ^~~~~~~~~~~~~
3rdparty/libprocess/3rdparty/stout/include/stout/unreachable.hpp|19 col 23| 
note: expanded from macro 'UNREACHABLE'
|| #define UNREACHABLE() Unreachable(__FILE__, __LINE__)
||                       ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
3rdparty/libprocess/3rdparty/stout/include/stout/result.hpp|51 col 3| note: 
candidate constructor [with U = Unreachable]
||   Result(const U& u)
||   ^
3rdparty/libprocess/3rdparty/stout/include/stout/unreachable.hpp|27 col 3| 
note: candidate function [with T = Result<unsigned int>]
||   operator T () const


- Dominic


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


On May 21, 2014, 9:24 a.m., Dominic Hamon wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/21777/
> -----------------------------------------------------------
> 
> (Updated May 21, 2014, 9:24 a.m.)
> 
> 
> Review request for mesos, Till Toenshoff and Vinod Kone.
> 
> 
> Repository: mesos-git
> 
> 
> Description
> -------
> 
> see summary
> 
> Without the explicit conversion some compilers find the conversion from 
> Unreachable() to Result<T>() ambiguous.
> 
> 
> Diffs
> -----
> 
>   3rdparty/libprocess/3rdparty/stout/include/stout/os.hpp 
> 94d8b4c7fcf83946e2f9dd0f3e746889599ca174 
> 
> Diff: https://reviews.apache.org/r/21777/diff/
> 
> 
> Testing
> -------
> 
> able to build on clang 3.4
> 
> 
> Thanks,
> 
> Dominic Hamon
> 
>

Reply via email to