From e21808de3cd06aee58c9987872571ae74d4438c8 Mon Sep 17 00:00:00 2001 From: Roland Conybeare Date: Sun, 29 Mar 2026 13:44:19 -0400 Subject: [PATCH] xo-gc stack: + request-gc-statistics() primitive 1. xo-gc now depends on xo-object2. 2. use genfacet for ICollector_DX1Collector 3. moves xo-gc utest previously in xo-object2 to more natural location in xo-gc/ --- include/xo/interpreter2/detail/IRuntimeContext_DVsmRcx.hpp | 2 ++ src/interpreter2/IRuntimeContext_DVsmRcx.cpp | 6 ++++++ 2 files changed, 8 insertions(+) diff --git a/include/xo/interpreter2/detail/IRuntimeContext_DVsmRcx.hpp b/include/xo/interpreter2/detail/IRuntimeContext_DVsmRcx.hpp index 1eddf28c..d87596e6 100644 --- a/include/xo/interpreter2/detail/IRuntimeContext_DVsmRcx.hpp +++ b/include/xo/interpreter2/detail/IRuntimeContext_DVsmRcx.hpp @@ -52,6 +52,8 @@ namespace xo { static obj allocator(const DVsmRcx & self) noexcept; /** collector facet for allocator. If non-null, same data pointer as allocator **/ static obj collector(const DVsmRcx & self) noexcept; + /** last-resort allocator for erros. e.g. regular allocator exhausted **/ + static obj error_allocator(const DVsmRcx & self) noexcept; /** stringtable for unique symbols **/ static StringTable * stringtable(const DVsmRcx & self) noexcept; /** invoke visitor for each distinct memory pool **/ diff --git a/src/interpreter2/IRuntimeContext_DVsmRcx.cpp b/src/interpreter2/IRuntimeContext_DVsmRcx.cpp index 9b1a73d0..b2259c75 100644 --- a/src/interpreter2/IRuntimeContext_DVsmRcx.cpp +++ b/src/interpreter2/IRuntimeContext_DVsmRcx.cpp @@ -27,6 +27,12 @@ namespace xo { return self.collector(); } + auto + IRuntimeContext_DVsmRcx::error_allocator(const DVsmRcx & self) noexcept -> obj + { + return self.error_allocator(); + } + auto IRuntimeContext_DVsmRcx::stringtable(const DVsmRcx & self) noexcept -> StringTable * {