[ox/std] Add oxModelFwdDecl macro for broken Apple Clang
This commit is contained in:
parent
3ae1d6c897
commit
da23c9304d
4
deps/ox/src/ox/model/def.hpp
vendored
4
deps/ox/src/ox/model/def.hpp
vendored
@ -10,8 +10,10 @@
|
||||
|
||||
#include <ox/std/concepts.hpp>
|
||||
|
||||
// oxModelFwdDecl is necessary because Apple-Clang is broken...
|
||||
#define oxModelFwdDecl(modelName) constexpr ox::Error model(auto *io, ox::CommonPtrWith<modelName> auto *o) noexcept
|
||||
#define oxModelBegin(modelName) constexpr ox::Error model(auto *io, [[maybe_unused]] ox::CommonPtrWith<modelName> auto *o) noexcept { oxReturnError(io->template setTypeInfo<modelName>());
|
||||
#define oxModelEnd() return OxError(0); }
|
||||
#define oxModelField(fieldName) oxReturnError(io->field(#fieldName, &o->fieldName));
|
||||
#define oxModelFieldRename(objFieldName, serFieldName) oxReturnError(io->field(#serFieldName, &o->objFieldName));
|
||||
#define oxModelFriend(modelName) friend constexpr ox::Error model(auto*, ox::CommonPtrWith<modelName> auto*) noexcept
|
||||
#define oxModelFriend(modelName) friend constexpr ox::Error model(auto *io, ox::CommonPtrWith<modelName> auto *o) noexcept
|
||||
|
Loading…
Reference in New Issue
Block a user