video_core: texture_cache: proper `UniqueImage` class movers
This commit is contained in:
parent
a67b8f7a0b
commit
055dec1149
|
@ -53,9 +53,14 @@ struct UniqueImage {
|
|||
UniqueImage(const UniqueImage&) = delete;
|
||||
UniqueImage& operator=(const UniqueImage&) = delete;
|
||||
|
||||
UniqueImage(UniqueImage&& other) : image{std::exchange(other.image, VK_NULL_HANDLE)} {}
|
||||
UniqueImage(UniqueImage&& other)
|
||||
: image{std::exchange(other.image, VK_NULL_HANDLE)},
|
||||
allocator{std::exchange(other.allocator, VK_NULL_HANDLE)},
|
||||
allocation{std::exchange(other.allocation, VK_NULL_HANDLE)} {}
|
||||
UniqueImage& operator=(UniqueImage&& other) {
|
||||
image = std::exchange(other.image, VK_NULL_HANDLE);
|
||||
allocator = std::exchange(other.allocator, VK_NULL_HANDLE);
|
||||
allocation = std::exchange(other.allocation, VK_NULL_HANDLE);
|
||||
return *this;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue