Codechange: replace memmove with std::move(_backwards)

This commit is contained in:
Rubidium
2025-05-08 22:06:29 +02:00
committed by rubidium42
parent 3cd040ffe9
commit 568b70e556
4 changed files with 5 additions and 3 deletions

View File

@@ -803,7 +803,8 @@ static void CompactSpriteCache()
GetSpriteCache(i)->ptr = s->data; // Adjust sprite array entry
/* Swap this and the next block */
temp = *s;
memmove(s, next, next->size);
std::byte *p = reinterpret_cast<std::byte *>(next);
std::move(p, &p[next->size], reinterpret_cast<std::byte *>(s));
s = NextBlock(s);
*s = temp;