Re: Structured bindings and minimum GCC & clang versions

2019-08-16 Thread Henri Sivonen
On Fri, Aug 16, 2019 at 9:51 AM Eric Rahm  wrote:
>
> We are actively working on this. Unfortunately, as expected, its never as
> simple as we'd like. Updating the minimum gcc version (
> https://bugzilla.mozilla.org/show_bug.cgi?id=1536848) is blocked on getting
> our hazard builds updated, updating to c++17 has some of it's own quirks.

Thanks. The dependencies indeed look tricky. :-(

I take it that doing what Chromium does and shipping a statically
linked symbol-swapped copy of libc++ instead of depending on the
system C++ standard library would have its own set of issues. :-(

-- 
Henri Sivonen
hsivo...@mozilla.com
___
dev-platform mailing list
dev-platform@lists.mozilla.org
https://lists.mozilla.org/listinfo/dev-platform


Re: Structured bindings and minimum GCC & clang versions

2019-08-16 Thread Eric Rahm
We are actively working on this. Unfortunately, as expected, its never as
simple as we'd like. Updating the minimum gcc version (
https://bugzilla.mozilla.org/show_bug.cgi?id=1536848) is blocked on getting
our hazard builds updated, updating to c++17 has some of it's own quirks.
We're currently at the point where doing a try build w/ c++17 enabled on
linux works.


On Thu, Aug 15, 2019 at 11:45 PM Gerald Squelart 
wrote:

> On Friday, August 16, 2019 at 4:19:20 PM UTC+10, Henri Sivonen wrote:
> > This week, I wrote some code that made me wish we already had support
> > for structured bindings and return by initializer list (both from
> > C++17) for mozilla::Tuple.
> >
> > That is, if we have
> > mozilla::Tuple Foo()
> > it would be nice to be able to call it via
> > auto [a, b] = Foo();
> > and within Foo to write returns as
> > return { a, b };
> >
> > It appears that our minimum GCC and minimum clang documented at
> >
> https://developer.mozilla.org/en-US/docs/Mozilla/Using_CXX_in_Mozilla_code
> > are pretty old.
> >
> > What's the current outlook for increasing the minimum GCC and clang
> > versions such that we could start using structured bindings and return
> > by initializer list for tuples (either by making sure mozilla::Tuple
> > support these or by migrating from mozilla::Tuple to std::tuple) and
> > thereby get ergonomic multiple return values in C++?
> >
> > --
> > Henri Sivonen
> > hsi...@mozilla.com
>
> I'm guessing that https://bugzilla.mozilla.org/show_bug.cgi?id=1560664
> will deal with compiler details. (I don't think we can use a C++17 feature
> without enabling C++17 overall -- right?)
>
> I too am eager to start using C++17, mostly constexpr-if.
>
> Cheers,
> Gerald
> ___
> dev-platform mailing list
> dev-platform@lists.mozilla.org
> https://lists.mozilla.org/listinfo/dev-platform
>
___
dev-platform mailing list
dev-platform@lists.mozilla.org
https://lists.mozilla.org/listinfo/dev-platform


Re: Structured bindings and minimum GCC & clang versions

2019-08-16 Thread Gerald Squelart
On Friday, August 16, 2019 at 4:19:20 PM UTC+10, Henri Sivonen wrote:
> This week, I wrote some code that made me wish we already had support
> for structured bindings and return by initializer list (both from
> C++17) for mozilla::Tuple.
> 
> That is, if we have
> mozilla::Tuple Foo()
> it would be nice to be able to call it via
> auto [a, b] = Foo();
> and within Foo to write returns as
> return { a, b };
> 
> It appears that our minimum GCC and minimum clang documented at
> https://developer.mozilla.org/en-US/docs/Mozilla/Using_CXX_in_Mozilla_code
> are pretty old.
> 
> What's the current outlook for increasing the minimum GCC and clang
> versions such that we could start using structured bindings and return
> by initializer list for tuples (either by making sure mozilla::Tuple
> support these or by migrating from mozilla::Tuple to std::tuple) and
> thereby get ergonomic multiple return values in C++?
> 
> -- 
> Henri Sivonen
> hsi...@mozilla.com

I'm guessing that https://bugzilla.mozilla.org/show_bug.cgi?id=1560664 will 
deal with compiler details. (I don't think we can use a C++17 feature without 
enabling C++17 overall -- right?)

I too am eager to start using C++17, mostly constexpr-if.

Cheers,
Gerald
___
dev-platform mailing list
dev-platform@lists.mozilla.org
https://lists.mozilla.org/listinfo/dev-platform