Skip to content

Commit

Permalink
Fix gcc/clang errors
Browse files Browse the repository at this point in the history
  • Loading branch information
stephen-webb committed Oct 19, 2023
1 parent f484770 commit a58d8e9
Showing 1 changed file with 8 additions and 4 deletions.
12 changes: 8 additions & 4 deletions src/main/include/log4cxx/helpers/widelife.h
Original file line number Diff line number Diff line change
Expand Up @@ -36,13 +36,17 @@ template <class T>
class WideLife
{
public:
template <class... Args>
WideLife()
{
new(&storage) T();
}
template <class Arg0, class... Args>
#if defined(__cpp_concepts) && __cpp_concepts >= 201500
requires (!std::same_as<WideLife, Args...>)
requires (!std::same_as<WideLife, Arg0>)
#endif
WideLife(Args&&... args)
WideLife(Arg0 arg0, Args&&... args)
{
new(&storage) T(std::forward<Args>(args)...);
new(&storage) T(arg0, std::forward<Args>(args)...);
}

~WideLife()
Expand Down

0 comments on commit a58d8e9

Please sign in to comment.