[libcxx-commits] [PATCH] D118940: [libc++] Fix std::__debug_less in c++17.

Nikolas Klauser via Phabricator via libcxx-commits libcxx-commits at lists.llvm.org
Thu Feb 3 12:51:56 PST 2022


philnik accepted this revision as: philnik.
philnik added a comment.

LGTM % nits.



================
Comment at: libcxx/include/__algorithm/comp_ref_type.h:25
 
 #ifdef _LIBCPP_DEBUG
 
----------------
Pre-existing: This should be `_LIBCPP_DEBUG_LEVEL == 1`.


================
Comment at: libcxx/include/__algorithm/comp_ref_type.h:56
+    _LIBCPP_CONSTEXPR_AFTER_CXX11
     inline _LIBCPP_INLINE_VISIBILITY
     decltype((void)declval<_Compare&>()(
----------------
Please replace `_LIBCPP_INLINE_VISIBILITY` with `_LIBCPP_HIDE_FROM_ABI` as a fly-by.


================
Comment at: libcxx/test/libcxx/algorithms/debug_less.pass.cpp:276
     std::less<> cmp{};
     __debug_less<std::less<> > dcmp(cmp);
     assert(dcmp(1, 2));
----------------



Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D118940/new/

https://reviews.llvm.org/D118940



More information about the libcxx-commits mailing list