Daily bit(e) of C++ | decltype(auto)
Daily bit(e) of C++ #405, Automatic type deduction that follows decltype rules instead of auto type-deduction: decltype(auto).
One problem you can run into with auto type-deduction is when using auto to deduce the result type of a function.
The solution can be decltype(auto), which, unsurprisingly, follows the decltype rules for determining the type.