Skip to content

Commit

Permalink
Deducing guide for clang
Browse files Browse the repository at this point in the history
  • Loading branch information
JohanMabille committed Apr 6, 2024
1 parent 5771fd2 commit 55c8b9e
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions include/sparrow/allocator.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -147,9 +147,10 @@ namespace sparrow
return std::forward<A>(alloc);
}

template <class... Ts>
struct overloaded : Ts... { using Ts::operator()...; };

template <class... Ts> struct overloaded : Ts... { using Ts::operator()...; };
// Although not required in C++20, clang needs it to build the code below
template <class... Ts> overloaded(Ts...) -> overloaded<Ts...>;

storage_type copy_storage(const storage_type& rhs) const
{
return std::visit(overloaded {
Expand Down

0 comments on commit 55c8b9e

Please sign in to comment.