diff --git a/print-zero-even-odd/index.ixx b/print-zero-even-odd/index.ixx index e3134d03..a7050a35 100644 --- a/print-zero-even-odd/index.ixx +++ b/print-zero-even-odd/index.ixx @@ -1,8 +1,8 @@ module; -#include -#include +#include +#include export module leetcode_test.print_zero_even_odd.ZeroEvenOdd; import leetcode_test.print_foobar_alternately.BlockingQueue; using leetcode_test::print_foobar_alternately::BlockingQueue; diff --git a/split-a-circular-linked-list/test.cpp b/split-a-circular-linked-list/test.cpp index 7a22de8a..233f8e1c 100644 --- a/split-a-circular-linked-list/test.cpp +++ b/split-a-circular-linked-list/test.cpp @@ -17,28 +17,31 @@ using namespace leetcode_test::split_a_circular_linked_list; using namespace std; using std::vector; template -concept sizable = requires(T& t) { +concept sizable = requires(T& t) +{ { t.size() - } -> std::same_as; + } -> std::same_as; }; template -concept iterable = requires(T& t) { +concept iterable = requires(T& t) +{ ++t.begin(); { t.begin() != t.end() - } -> std::same_as; + } -> std::same_as; }; template -concept equalable = requires(T& t, Y& y, size_t i) { +concept equalable = requires(T& t, Y& y, size_t i) +{ { *t.begin() == *y.begin() - } -> std::same_as; + } -> std::same_as; }; template - requires sizable and sizable and equalable and iterable and iterable +requires sizable and sizable and equalable and iterable and iterable auto assertContentEquals(T& left, Y& right) { diff --git a/web-crawler-multithreaded/test.cpp b/web-crawler-multithreaded/test.cpp index df408e94..e132719a 100644 --- a/web-crawler-multithreaded/test.cpp +++ b/web-crawler-multithreaded/test.cpp @@ -11,27 +11,30 @@ import leetcode_test.web_crawler_multithreaded.Solution; using namespace std; using namespace leetcode_test::web_crawler_multithreaded; template -concept sizable = requires(T& t) { +concept sizable = requires(T& t) +{ { t.size() - } -> std::same_as; + } -> std::same_as; }; template -concept iterable = requires(T& t) { +concept iterable = requires(T& t) +{ ++t.begin(); { t.begin() != t.end() - } -> std::same_as; + } -> std::same_as; }; template -concept equalable = requires(T& t, Y& y, size_t i) { +concept equalable = requires(T& t, Y& y, size_t i) +{ { *t.begin() == *y.begin() - } -> std::same_as; + } -> std::same_as; }; template - requires sizable and sizable and equalable and iterable and iterable +requires sizable and sizable and equalable and iterable and iterable auto assertContentEquals(const T& left, const Y& right) {