[ox] Make model system's setTypeInfo return an Error
This commit is contained in:
4
deps/ox/src/ox/mc/test/tests.cpp
vendored
4
deps/ox/src/ox/mc/test/tests.cpp
vendored
@ -61,7 +61,7 @@ struct TestStruct {
|
||||
|
||||
template<typename T>
|
||||
constexpr ox::Error model(T *io, ox::CommonPtrWith<TestUnion> auto *obj) noexcept {
|
||||
io->template setTypeInfo<TestUnion>();
|
||||
oxReturnError(io->template setTypeInfo<TestUnion>());
|
||||
oxReturnError(io->field("Bool", &obj->Bool));
|
||||
oxReturnError(io->field("Int", &obj->Int));
|
||||
oxReturnError(io->fieldCString("CString", &obj->CString));
|
||||
@ -76,7 +76,7 @@ oxModelEnd()
|
||||
|
||||
template<typename T>
|
||||
constexpr ox::Error model(T *io, ox::CommonPtrWith<TestStruct> auto *obj) noexcept {
|
||||
io->template setTypeInfo<TestStruct>();
|
||||
oxReturnError(io->template setTypeInfo<TestStruct>());
|
||||
oxReturnError(io->field("Vector", &obj->Vector));
|
||||
oxReturnError(io->field("Bool", &obj->Bool));
|
||||
oxReturnError(io->field("Int", &obj->Int));
|
||||
|
Reference in New Issue
Block a user