Skip to content

Commit

Permalink
Fix clang -Wdeprecated-copy.
Browse files Browse the repository at this point in the history
The copy constructor must be explicitly defined (here, defaulted) to be
available when the assignment operator is deleted.  While there is a
templated constructor from VmaStlAlloc<U>, the compiler doesn't consider
this to be a "copy" constructor for purposes of the warning.
  • Loading branch information
pkasting committed Jun 8, 2021
1 parent 4a132e5 commit a850ffb
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions include/vk_mem_alloc.h
Original file line number Diff line number Diff line change
Expand Up @@ -4963,6 +4963,7 @@ class VmaStlAllocator
}

VmaStlAllocator& operator=(const VmaStlAllocator& x) = delete;
VmaStlAllocator(const VmaStlAllocator&) = default;
};

#if VMA_USE_STL_VECTOR
Expand Down

0 comments on commit a850ffb

Please sign in to comment.