[*] amend/added soo vis

This commit is contained in:
Reece Wilson 2023-03-21 03:01:40 +00:00
parent 5e0678e628
commit 2cc67786eb

View File

@ -28,7 +28,7 @@
#define _AUROXTL_INTERRFACE_SOO_EMITTER_2(a) AU_EMIT_SECOND a
#define _AUROXTL_INTERRFACE_SOO_EMITTER_3(a) , AU_EMIT_SECOND a
#define AUROXTL_INTERFACE_SOO_HDR_(type, maxSize, ...) \
#define AUROXTL_INTERFACE_SOO_HDR_(vis, type, maxSize, ...) \
protected: \
char padding[maxSize] {}; \
inline type(std::nullptr_t) \
@ -36,13 +36,13 @@
public: \
static const AuUInt kSSOPaddedSize = maxSize; \
static const AuUInt kSSORealSize; \
type(AU_FOR_EACH_FIRST(_AUROXTL_INTERRFACE_SOO_EMITTER_0, _AUROXTL_INTERRFACE_SOO_EMITTER_1, ## __VA_ARGS__));\
~type();
vis type(AU_FOR_EACH_FIRST(_AUROXTL_INTERRFACE_SOO_EMITTER_0, _AUROXTL_INTERRFACE_SOO_EMITTER_1, ## __VA_ARGS__));\
vis ~type();
#define AUROXTL_INTERFACE_SOO_HDR(Type, extends, targetSize, ...) \
#define AUROXTL_INTERFACE_SOO_HDR_EX(vis, Type, extends, targetSize, ...) \
struct Type ## SOO \
{ \
AUROXTL_INTERFACE_SOO_HDR_(Type ## SOO, targetSize, ## __VA_ARGS__) \
AUROXTL_INTERFACE_SOO_HDR_(vis, Type ## SOO, targetSize, ## __VA_ARGS__) \
inline extends *operator ->() \
{ \
return (extends *)this->padding; \
@ -79,8 +79,12 @@ struct Type ## SOO \
}; \
using Type ## SOO_t = Type ## SOO;
#define AUROXTL_INTERFACE_SOO_SRC(Type, FullType, ...) \
Type ## SOO::Type ## SOO(AU_FOR_EACH_FIRST(_AUROXTL_INTERRFACE_SOO_EMITTER_0, _AUROXTL_INTERRFACE_SOO_EMITTER_1, ## __VA_ARGS__)) \
#define AUROXTL_INTERFACE_SOO_HDR(Type, extends, targetSize, ...) \
AUROXTL_INTERFACE_SOO_HDR_EX(, Type, extends, targetSize, ## __VA_ARGS__)
#define AUROXTL_INTERFACE_SOO_SRC_EX(vis, Type, FullType, ...) \
vis Type ## SOO::Type ## SOO(AU_FOR_EACH_FIRST(_AUROXTL_INTERRFACE_SOO_EMITTER_0, _AUROXTL_INTERRFACE_SOO_EMITTER_1, ## __VA_ARGS__)) \
{ \
if (kSSORealSize > kSSOPaddedSize) \
{ \
@ -93,12 +97,17 @@ Type ## SOO::Type ## SOO(AU_FOR_EACH_FIRST(_AUROXTL_INTERRFACE_SOO_EMITTER_0, _A
} \
} \
\
Type ## SOO::~ Type ## SOO() \
vis Type ## SOO::~ Type ## SOO() \
{ \
_AUROXTL_INTERRFACE_SOO_THIS(FullType)->~FullType(); \
} \
const AuUInt Type ## SOO::kSSORealSize = sizeof(FullType);
#define AUROXTL_INTERFACE_SOO_SRC(Type, FullType, ...) \
AUROXTL_INTERFACE_SOO_SRC_EX(, Type, FullType, ##__VA_ARGS__)
#if !defined(AU_SHARED_API_SOO)
#define AU_SHARED_API_SOO(name, size, type, ...) \
AU_SHARED_API_EX(, name, type, ##__VA_ARGS__) \