[v3 PATCH] Use constexpr addressof in optional, SFINAE housekeeping for any, optional and tuple.

Jonathan Wakely jwakely@redhat.com
Sun Nov 13 21:06:00 GMT 2016


On 26/10/16 20:10 +0300, Ville Voutilainen wrote:
>    Use constexpr addressof in optional, SFINAE housekeeping
>    for any, optional and tuple.
>    * include/std/any (__do_emplace(_Args&&...)): New.
>    (__do_emplace(initializer_list<_Up>, _Args&&...)): Likewise.
>    (__any_constructible): Likewise.
>    (__any_constructible_t): Use __any_constructible.
>    (operator=(_ValueType&&)): SFINAE in the return type.
>    (emplace(_Args&&...)): Likewise.
>    (emplace(initializer_list<_Up>, _Args&&...)): Likewise.
>    * include/std/optional (_Has_addressof_mem): Remove.
>    (_Has_addressof_free): Likewise.
>    (_Has_addressof): Likewise.
>    (__constexpr_addressof(_Tp&)): Likewise.
>    (operator->): Use std::__addressof.
>    * include/std/tuple (operator=(const tuple<_UElements...>&)):
>    SFINAE in return type.
>    (operator=(tuple<_UElements...>&&)): Likewise.
>    * testsuite/20_util/any/misc/any_cast_neg.cc: Adjust.

OK for trunk, thanks.



More information about the Gcc-patches mailing list