Replace time-based GC with allocation-count trigger, migrate all Create factories to GCList::Create(), fix VFSPath root path, reorder TObject variant

This commit is contained in:
2026-09-01 05:15:43 -05:00
parent 56b74dc6fc
commit 2430b62232
38 changed files with 888 additions and 806 deletions
+2 -16
View File
@@ -1,22 +1,8 @@
#include "CrossLang.hpp"
namespace Tesses::CrossLang {
TAny *TAny::Create(GCList &ls) {
TAny *anyObj = new TAny();
std::shared_ptr<GC> gc = ls.GetGC();
ls.Add(anyObj);
gc->Watch(anyObj);
return anyObj;
}
TAny *TAny::Create(GCList *ls) {
TAny *anyObj = new TAny();
std::shared_ptr<GC> gc = ls->GetGC();
ls->Add(anyObj);
gc->Watch(anyObj);
return anyObj;
}
TAny *TAny::Create(GCList &ls) { return ls.Create<TAny>(); }
TAny *TAny::Create(GCList *ls) { return ls->Create<TAny>(); }
void TAny::Mark() {
if (this->marked)
return;