xo-reader2 stack: + xo-numeric + setup multi dispatch for *,/

This commit is contained in:
Roland Conybeare 2026-02-18 21:47:02 -08:00
commit d6bf210714
37 changed files with 1057 additions and 83 deletions

View file

@ -0,0 +1,31 @@
/** @file IntegerOps.cpp
*
* @author Roland Conybeare, Feb 2026
**/
#include "IntegerOps.hpp"
#include "integer/INumeric_DInteger.hpp"
namespace xo {
using xo::mm::AGCObject;
namespace scm {
obj<AGCObject>
IntegerOps::multiply(obj<ARuntimeContext> rcx,
DInteger * x, DInteger * y)
{
return DInteger::box<AGCObject>(rcx.allocator(), x->value() * y->value());
}
obj<AGCObject>
IntegerOps::divide(obj<ARuntimeContext> rcx,
DInteger * x, DInteger * y)
{
return DInteger::box<AGCObject>(rcx.allocator(), x->value() / y->value());
}
}
}
/* end IntegerOps.cpp */