mirror of
https://github.com/Laupetin/OpenAssetTools.git
synced 2025-07-05 02:31:55 +00:00
Reformat code with clang format
This commit is contained in:
@ -15,7 +15,8 @@ InMemoryZoneOutputStream::ReusableEntry::ReusableEntry(void* startPtr, const siz
|
||||
: m_start_ptr(startPtr),
|
||||
m_end_ptr(reinterpret_cast<void*>(reinterpret_cast<uintptr_t>(startPtr) + entrySize * entryCount)),
|
||||
m_start_zone_ptr(startZonePtr),
|
||||
m_entry_size(entrySize), m_entry_count(entryCount)
|
||||
m_entry_size(entrySize),
|
||||
m_entry_count(entryCount)
|
||||
{
|
||||
}
|
||||
|
||||
@ -184,16 +185,16 @@ bool InMemoryZoneOutputStream::ReusableShouldWrite(void** pPtr, const size_t ent
|
||||
return true;
|
||||
}
|
||||
|
||||
for(const auto& entry : foundEntriesForType->second)
|
||||
for (const auto& entry : foundEntriesForType->second)
|
||||
{
|
||||
if(*pPtr >= entry.m_start_ptr && *pPtr < entry.m_end_ptr)
|
||||
if (*pPtr >= entry.m_start_ptr && *pPtr < entry.m_end_ptr)
|
||||
{
|
||||
assert((reinterpret_cast<uintptr_t>(*pPtr) - reinterpret_cast<uintptr_t>(entry.m_start_ptr)) % entrySize == 0);
|
||||
*pPtr = reinterpret_cast<void*>(entry.m_start_zone_ptr + (reinterpret_cast<uintptr_t>(*pPtr) - reinterpret_cast<uintptr_t>(entry.m_start_ptr)));
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
|
@ -1,12 +1,12 @@
|
||||
#pragma once
|
||||
#include "Writing/InMemoryZoneData.h"
|
||||
#include "Zone/Stream/IZoneOutputStream.h"
|
||||
#include "Zone/XBlock.h"
|
||||
|
||||
#include <stack>
|
||||
#include <unordered_map>
|
||||
#include <vector>
|
||||
|
||||
#include "Writing/InMemoryZoneData.h"
|
||||
#include "Zone/XBlock.h"
|
||||
#include "Zone/Stream/IZoneOutputStream.h"
|
||||
|
||||
class InMemoryZoneOutputStream final : public IZoneOutputStream
|
||||
{
|
||||
class ReusableEntry
|
||||
|
Reference in New Issue
Block a user