Commit 01f34d0b authored by Daniela Engert's avatar Daniela Engert Committed by Victor Zverovich

Fix library deprecation warning

Since C++17, using template specialization 'std::allocator<void>' in any shape or form (even just mentioning it) is deprecated! A simple workaround is replacing 'void' by another (preferably empty) type, e.g. 'fmt::monostate'.

Found by Clang 9 in Visual Studio.
parent 9a0a24f9
...@@ -618,8 +618,9 @@ template <typename T> struct user_allocator { ...@@ -618,8 +618,9 @@ template <typename T> struct user_allocator {
~user_allocator() = default; ~user_allocator() = default;
template <typename U> user_allocator(const user_allocator<U>&) {} template <typename U> user_allocator(const user_allocator<U>&) {}
pointer allocate(size_type cnt, pointer allocate(
typename std::allocator<void>::const_pointer = FMT_NULL) { size_type cnt,
typename std::allocator<fmt::monostate>::const_pointer = FMT_NULL) {
return new value_type[cnt]; return new value_type[cnt];
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment