diff --git a/Source/Engine/Core/Templates.h b/Source/Engine/Core/Templates.h index dbb6388fc..49da8b84a 100644 --- a/Source/Engine/Core/Templates.h +++ b/Source/Engine/Core/Templates.h @@ -21,7 +21,11 @@ namespace THelpers template struct TIsTriviallyDestructibleImpl { - enum { Value = __has_trivial_destructor(T) }; +#if defined(__clang__) && __clang_major__ >= 15 + enum { Value = __is_trivially_destructible(T) }; +#else + enum { Value = __has_trivial_destructor(T) }; +#endif }; } @@ -261,7 +265,11 @@ struct TIsCopyConstructible template struct TIsTriviallyCopyConstructible { - enum { Value = TOrValue<__has_trivial_copy(T), TIsPODType>::Value }; +#if defined(__clang__) && __clang_major__ >= 15 + enum { Value = TOrValue<__is_trivially_copyable(T), TIsPODType>::Value }; +#else + enum { Value = TOrValue<__has_trivial_copy(T), TIsPODType>::Value }; +#endif }; //////////////////////////////////////////////////////////////////////////////////// @@ -289,7 +297,11 @@ struct TIsTriviallyDestructible template struct TIsTriviallyCopyAssignable { - enum { Value = TOrValue<__has_trivial_assign(T), TIsPODType>::Value }; +#if defined(__clang__) && __clang_major__ >= 15 + enum { Value = TOrValue<__is_trivially_assignable(T, const T), TIsPODType>::Value }; +#else + enum { Value = TOrValue<__has_trivial_assign(T), TIsPODType>::Value }; +#endif }; ////////////////////////////////////////////////////////////////////////////////////