mirror of
https://github.com/Auties00/Reboot-Launcher.git
synced 2026-01-13 19:22:22 +01:00
<feat: New project structure>
<feat: New release>
This commit is contained in:
25
dependencies/reboot/Project Reboot 3.0/MemoryOps.h
vendored
Normal file
25
dependencies/reboot/Project Reboot 3.0/MemoryOps.h
vendored
Normal file
@@ -0,0 +1,25 @@
|
||||
#pragma once
|
||||
|
||||
#include "inc.h"
|
||||
|
||||
#include "EnableIf.h"
|
||||
#include "UnrealTypeTraits.h"
|
||||
|
||||
template <typename DestinationElementType, typename SourceElementType, typename SizeType>
|
||||
FORCEINLINE typename TEnableIf<!TIsBitwiseConstructible<DestinationElementType, SourceElementType>::Value>::Type ConstructItems(void* Dest, const SourceElementType* Source, SizeType Count, int ElementSize = sizeof(SourceElementType))
|
||||
{
|
||||
while (Count)
|
||||
{
|
||||
new (Dest) DestinationElementType(*Source);
|
||||
++(DestinationElementType*&)Dest;
|
||||
++Source;
|
||||
--Count;
|
||||
}
|
||||
}
|
||||
|
||||
template <typename DestinationElementType, typename SourceElementType, typename SizeType>
|
||||
FORCEINLINE typename TEnableIf<TIsBitwiseConstructible<DestinationElementType, SourceElementType>::Value>::Type ConstructItems(void* Dest, const SourceElementType* Source, SizeType Count, int ElementSize = sizeof(SourceElementType))
|
||||
{
|
||||
// FMemory::Memcpy(Dest, Source, ElementSize * Count);
|
||||
memcpy(Dest, Source, ElementSize);
|
||||
}
|
||||
Reference in New Issue
Block a user