Skip to content

Commit

Permalink
Fix Appleclang compilation error (#2)
Browse files Browse the repository at this point in the history
  • Loading branch information
patrickroberts committed Feb 7, 2025
1 parent 801a056 commit 3c614bb
Showing 1 changed file with 6 additions and 5 deletions.
11 changes: 6 additions & 5 deletions include/beman/any_view/detail/intrusive_small_ptr.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -13,15 +13,16 @@ namespace beman::any_view::detail {

template <class InterfaceT>
concept interface_movable =
std::has_virtual_destructor_v<InterfaceT> and requires(InterfaceT instance, void* destination) {
std::has_virtual_destructor_v<InterfaceT> and requires(InterfaceT& instance, void* destination) {
{ instance.move_to(destination) } noexcept -> std::same_as<void>;
};

template <class InterfaceT>
concept interface_copyable = interface_movable<InterfaceT> and requires(const InterfaceT instance, void* destination) {
{ instance.copy_to(destination) } -> std::same_as<void>;
{ instance.copy() } -> std::same_as<InterfaceT*>;
};
concept interface_copyable =
interface_movable<InterfaceT> and requires(const InterfaceT& instance, void* destination) {
{ instance.copy_to(destination) } -> std::same_as<void>;
{ instance.copy() } -> std::same_as<InterfaceT*>;
};

enum class index_type : bool {
is_inplace,
Expand Down

0 comments on commit 3c614bb

Please sign in to comment.