> On Sept. 2, 2014, 7:50 p.m., Michael Park wrote:
> > Just something to note here, there's a bug in earlier GCC versions where
> > the access control of `= default`ed functions aren't enforced correctly.
> >
> > e.g.
> >
> > ```
> > class Foo
> > {
> > private:
> >
> > Foo() = default;
> >
> > };
> >
> > class Bar
> > {
> > private:
> >
> > Bar() {}
> >
> > };
> >
> > int main() {
> > Foo foo; // Foo::Foo() is private but not enforced.
> > // Bar bar; // error: 'Bar::Bar()' is private.
> > }
> > ```
> >
> > The above code snippet compiles fine with GCC-4.6.
>
> Vinod Kone wrote:
> does it work correctly for gcc-4.4? if yes, it should be fine.
Things will continue to compile. However if you were using visibility to
enforce that people use a factory to construct your class and you used '=
default' to make the constructor private, on the older compiler someone can
write code which calls the constructor directly.
- Cody
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/25261/#review52067
-----------------------------------------------------------
On Sept. 2, 2014, 5:57 p.m., Dominic Hamon wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/25261/
> -----------------------------------------------------------
>
> (Updated Sept. 2, 2014, 5:57 p.m.)
>
>
> Review request for mesos and Benjamin Hindman.
>
>
> Bugs: MESOS-1752 and MESOS-1753
> https://issues.apache.org/jira/browse/MESOS-1752
> https://issues.apache.org/jira/browse/MESOS-1753
>
>
> Repository: mesos-git
>
>
> Description
> -------
>
> add c++11 language features to m4 macro that checks for c++11 support
>
>
> Diffs
> -----
>
> m4/ax_cxx_compile_stdcxx_11.m4 07b298f151094e818287f741b3e0efd28374e82b
>
> Diff: https://reviews.apache.org/r/25261/diff/
>
>
> Testing
> -------
>
> built with g++-4.4, the minimum compiler we support.
>
>
> Thanks,
>
> Dominic Hamon
>
>