From 897a59cdad66e593fd45eece9414d8414fa7f1ae Mon Sep 17 00:00:00 2001 From: Gary Talent Date: Thu, 23 Jan 2025 23:51:13 -0600 Subject: [PATCH] Squashed 'deps/nostalgia/' changes from e40b1124..7e3e0461 7e3e0461 [ox/model] Fix possible infinite recursion git-subtree-dir: deps/nostalgia git-subtree-split: 7e3e0461097fb87807237e5494f8cd6ba289dd87 --- deps/ox/src/ox/model/typestore.hpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/deps/ox/src/ox/model/typestore.hpp b/deps/ox/src/ox/model/typestore.hpp index e27f0e3..3646c3b 100644 --- a/deps/ox/src/ox/model/typestore.hpp +++ b/deps/ox/src/ox/model/typestore.hpp @@ -58,7 +58,11 @@ class TypeStore { if (!std::is_constant_evaluated()) { OX_REQUIRE_M(dt, loadDescriptor(typeId)); for (auto &f : dt->fieldList) { - OX_RETURN_ERROR(this->getLoad(f.typeId).moveTo(f.type)); + if (typeId == f.typeId) { + f.type = dt.get(); + } else { + OX_RETURN_ERROR(this->getLoad(f.typeId).moveTo(f.type)); + } } auto &out = m_cache[typeId]; out = std::move(dt);