This is the mail archive of the
libstdc++@gcc.gnu.org
mailing list for the libstdc++ project.
Re: [v3 PATCH] Make the default constructors of tuple and pair conditionally explicit.
- From: Paolo Carlini <paolo dot carlini at oracle dot com>
- To: Ville Voutilainen <ville dot voutilainen at gmail dot com>, "gcc-patches at gcc dot gnu dot org" <gcc-patches at gcc dot gnu dot org>, libstdc++ at gcc dot gnu dot org
- Date: Mon, 2 Nov 2015 16:19:39 +0100
- Subject: Re: [v3 PATCH] Make the default constructors of tuple and pair conditionally explicit.
- Authentication-results: sourceware.org; auth=none
- References: <CAFk2RUaUjmpsbvQdonwR2SaqjAMHk2tjaBrKjM1Gy8jmJg1Ufg at mail dot gmail dot com>
Hi Ville,
On 11/01/2015 04:27 AM, Ville Voutilainen wrote:
In the last meeting, while processing LWG 2510, LWG's guidance
was to make the default constructors of pair and tuple conditionally
explicit. This patch implements a new trait and uses it in pair and tuple.
Paolo, Jonathan is traveling and somewhat unlikely to be able to review
this for quite some time, could you please review this patch?
Sure, Jonathan told me a few weeks ago. Note anyway that I would not
expect major issues with committing this kind of patch even after the
end of Stage 1...
Anyway, so far the only detail which makes me a little nervous is the
following:
+ template <typename _Tp>
+ struct __is_implicitly_default_constructible
+ : public integral_constant<bool,
+ (is_default_constructible<_Tp>::value
+ && __is_implicitly_default_constructible_safe<_Tp>::value)>
I think we want to use __and_ (note that there isn't a single logical &&
in the whole type_traits, outside macros).
Paolo.