xo-object2: utest: ++ allocation in collector utest

This commit is contained in:
Roland Conybeare 2026-01-02 18:55:53 -05:00
commit 3f1470f938
18 changed files with 196 additions and 26 deletions

View file

@ -0,0 +1,24 @@
/** @file DFloat.cpp
*
* @author Roland Conybeare, Dec 2025
**/
#include "DFloat.hpp"
namespace xo {
using xo::facet::typeseq;
namespace scm {
DFloat *
DFloat::make(obj<AAllocator> mm,
double x)
{
void * mem = mm.alloc(typeseq::id<DFloat>(),
sizeof(DFloat));
return new (mem) DFloat(x);
}
} /*namespace scm*/
} /*namespace xo*/
/* end DFloat.cpp */