An issue with operator() was found during the implementation of https://reviews.llvm.org/D132268.
This patch aims to resolve the issues by updating the operator to use perfect forwarding.
The original motivation for three_way_comp_ref_type is given in: https://reviews.llvm.org/D131395
three_way_comp_ref_type's implementation is inspired by comp_ref_type, which has two overloads:
template <class _Tp, class _Up> bool operator()(const _Tp& __x, const _Up& __y); template <class _Tp, class _Up> bool operator()(_Tp& __x, _Up& __y);
__debug_three_way_comp is missing the first overload and also declares the typealias`_three_way_comp_ref_type ` incorrectly.
"three_way_comp_ref_type's implementation is inspired by comp_ref_type, which has two overloads:"
I'm a bit confused. Here you don't use two overloads. Can you explain the difference between the message and the implementation?