This is the mail archive of the libstdc++@gcc.gnu.org mailing list for the libstdc++ project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [patch] Simplify std::tuple helpers and fix C++14 bug.


2014-05-15 0:22 GMT+02:00 Jonathan Wakely <jwakely@redhat.com>:
> I found a bug in the new std::get<Tp>(tuple<Types...>&&) function
> where it didn't compile when trying to access reference member.
>
> The rest of this patch simplifies the code in <tuple> by:
>
> - removing the redundant __add_ref etc. helpers.
> - defining a __tuple_element_t alias template.
> - removing duplication in the tuple_size<cv T> traits.
> - using static_assert in the relational operators.

Looking at the definition of the new alias

__cv_tuple_size

you might want to apply LWG 2313

http://cplusplus.github.io/LWG/lwg-defects.html#2313

and simplify its definition even further.

- Daniel


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]