From 388cf58b31d6480007901785851e6369b0efe64b Mon Sep 17 00:00:00 2001 From: comex Date: Tue, 29 Dec 2020 14:26:16 -0500 Subject: k_priority_queue: Fix concepts use - For `std::same_as`, add missing include of ``. - For `std::convertible_to`, create a replacement in `common/concepts.h` and use that instead. This would also be found in ``, but unlike `std::same_as`, `std::convertible_to` is not yet implemented in libc++, LLVM's STL implementation - not even in master. (In fact, `std::same_as` is the *only* concept currently implemented. For some reason.) --- src/common/concepts.h | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'src/common') diff --git a/src/common/concepts.h b/src/common/concepts.h index 5bef3ad67..aa08065a7 100644 --- a/src/common/concepts.h +++ b/src/common/concepts.h @@ -31,4 +31,8 @@ concept DerivedFrom = requires { std::is_convertible_v; }; +// TODO: Replace with std::convertible_to when libc++ implements it. +template +concept ConvertibleTo = std::is_convertible_v; + } // namespace Common -- cgit v1.2.3