> On April 25, 2016, 7:24 a.m., Neil Conway wrote:
> > src/tests/containerizer/mesos_containerizer_tests.cpp, line 958
> > <https://reviews.apache.org/r/46593/diff/1/?file=1358228#file1358228line958>
> >
> >     Extra set of parentheses here doesn't seem useful. (Can you fix this 
> > where it occurs elsewhere in the test file?)

This extra pair of parentheses was added on purpose. Otherwise, the compile 
would failed:
```
../../src/tests/containerizer/mesos_containerizer_tests.cpp:603:35: error: 
parentheses were disambiguated as a function declaration 
[-Werror,-Wvexing-parse]
  MesosContainerizer containerizer(Owned<MesosContainerizerProcess>(process));
                                  ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
../../src/tests/containerizer/mesos_containerizer_tests.cpp:603:36: note: add a 
pair of parentheses to declare a variable
  MesosContainerizer containerizer(Owned<MesosContainerizerProcess>(process));
                                   ^
                                   (                                        )
```
This should be referred to as the "most vexing parse".


- Gilbert


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


On April 22, 2016, 4:48 p.m., Gilbert Song wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/46593/
> -----------------------------------------------------------
> 
> (Updated April 22, 2016, 4:48 p.m.)
> 
> 
> Review request for mesos, Artem Harutyunyan, Jie Yu, Neil Conway, and Timothy 
> Chen.
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> Added test for containerizer destroy while provisioning race.
> 
> 
> Diffs
> -----
> 
>   src/tests/containerizer/mesos_containerizer_tests.cpp 
> 09742ff21513dc2570684d384b257868dd57a9ce 
> 
> Diff: https://reviews.apache.org/r/46593/diff/
> 
> 
> Testing
> -------
> 
> make check
> 
> Verified that the test is 90% chance to be segfault if we reverted the fix.
> 
> 
> Thanks,
> 
> Gilbert Song
> 
>

Reply via email to