xo-interpreter adds + explict mm arg to ctors (retiring Object::mm)

This commit is contained in:
Roland Conybeare 2025-11-16 20:10:23 -05:00
commit f3e7330d92
38 changed files with 664 additions and 103 deletions

View file

@ -10,12 +10,13 @@
namespace xo {
using xo::reflect::Reflect;
using xo::reflect::TaggedPtr;
using xo::gc::IAlloc;
namespace obj {
Integer::Integer(int_type x) : value_{x} {}
gp<Integer>
Integer::make(int_type x) {
Integer::make(IAlloc * mm, int_type x) {
return new (MMPtr(mm)) Integer(x);
}
@ -41,7 +42,7 @@ namespace xo {
Object *
Integer::_shallow_copy() const {
Cpof cpof(this);
Cpof cpof(Object::mm, this);
return new (cpof) Integer(*this);
}