This is a follow-up question to my previous questions "Which parts of the C++14 Standard Library could be and which parts will be made constexpr
?" and "Guidelines to do constexpr
operator-overloading?"
In the runtime world, a nice idiom to overload operator<
for a struct of several data members, is to use std::tie
to convert a struct into a std::tuple
and piggy-back on its operator<
which does the Right Thing™ (lexicographic comparison on the various members).
In C++14, many parts of std::tuple
are made constexpr
, in particular make_tuple
, std::get
and the earlier mentioned operator<
. However, it appears that the seemingly related std::tie
is not marked constexpr
. This is rather annoying because it makes defining user-defined literal types that can be compared at compile-time more verbose than necessary.
Question: are there any technical reasons for which std::tie
is not marked constexpr
for C++14?
UPDATE: LWG issue 2301, implemented in libc++ and libstdc++ bug 65978
UPDATE2: fixed by @JonathanWakely a little over 3 hours after submitting the libstdc++ bug report!