[libcxx-commits] [PATCH] D146250: [libc++][spaceship] Implement `operator<=>` for `time_point`

Mark de Wever via Phabricator via libcxx-commits libcxx-commits at lists.llvm.org
Tue Mar 21 12:50:49 PDT 2023


Mordante added a comment.

In general LGTM modulo some nits.



================
Comment at: libcxx/test/std/time/time.point/time.point.comparisons/compare.three_way.pass.cpp:22
+#include <chrono>
+#include <compare>
+
----------------
Pedantic, but this include is mandated not to be required. The chrono header is required to include this header.
(http://eel.is/c++draft/time.syn)



================
Comment at: libcxx/test/std/time/time.point/time.point.comparisons/compare.three_way.pass.cpp:31
+  using T1        = std::chrono::time_point<Clock, Duration1>;
+  using T2        = std::chrono::time_point<Clock, Duration2>;
+
----------------
I would prefer to have some test where `Duration::rep` is a floating-point type.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D146250



More information about the libcxx-commits mailing list