refactor: make AGCObject.shallow_copy() non-const

prep for moving to ACollector interface
This commit is contained in:
Roland Conybeare 2026-04-04 14:38:14 -04:00
commit b91f45d934
10 changed files with 15 additions and 20 deletions

View file

@ -52,10 +52,10 @@ namespace xo {
// const methods
/** memory consumption for this instance **/
static size_type shallow_size(const DPrimitive_gco_0 & self) noexcept;
/** copy instance using allocator **/
static Opaque shallow_copy(const DPrimitive_gco_0 & self, obj<AAllocator> mm) noexcept;
// non-const methods
/** copy instance using allocator **/
static Opaque shallow_copy(DPrimitive_gco_0 & self, obj<AAllocator> mm) noexcept;
/** during GC: forward immdiate children **/
static size_type forward_children(DPrimitive_gco_0 & self, obj<ACollector> gc) noexcept;
///@}

View file

@ -52,10 +52,10 @@ namespace xo {
// const methods
/** memory consumption for this instance **/
static size_type shallow_size(const DPrimitive_gco_1_gco & self) noexcept;
/** copy instance using allocator **/
static Opaque shallow_copy(const DPrimitive_gco_1_gco & self, obj<AAllocator> mm) noexcept;
// non-const methods
/** copy instance using allocator **/
static Opaque shallow_copy(DPrimitive_gco_1_gco & self, obj<AAllocator> mm) noexcept;
/** during GC: forward immdiate children **/
static size_type forward_children(DPrimitive_gco_1_gco & self, obj<ACollector> gc) noexcept;
///@}

View file

@ -52,10 +52,10 @@ namespace xo {
// const methods
/** memory consumption for this instance **/
static size_type shallow_size(const DPrimitive_gco_2_dict_string & self) noexcept;
/** copy instance using allocator **/
static Opaque shallow_copy(const DPrimitive_gco_2_dict_string & self, obj<AAllocator> mm) noexcept;
// non-const methods
/** copy instance using allocator **/
static Opaque shallow_copy(DPrimitive_gco_2_dict_string & self, obj<AAllocator> mm) noexcept;
/** during GC: forward immdiate children **/
static size_type forward_children(DPrimitive_gco_2_dict_string & self, obj<ACollector> gc) noexcept;
///@}

View file

@ -52,10 +52,10 @@ namespace xo {
// const methods
/** memory consumption for this instance **/
static size_type shallow_size(const DPrimitive_gco_2_gco_gco & self) noexcept;
/** copy instance using allocator **/
static Opaque shallow_copy(const DPrimitive_gco_2_gco_gco & self, obj<AAllocator> mm) noexcept;
// non-const methods
/** copy instance using allocator **/
static Opaque shallow_copy(DPrimitive_gco_2_gco_gco & self, obj<AAllocator> mm) noexcept;
/** during GC: forward immdiate children **/
static size_type forward_children(DPrimitive_gco_2_gco_gco & self, obj<ACollector> gc) noexcept;
///@}

View file

@ -52,10 +52,10 @@ namespace xo {
// const methods
/** memory consumption for this instance **/
static size_type shallow_size(const DPrimitive_gco_3_dict_string_gco & self) noexcept;
/** copy instance using allocator **/
static Opaque shallow_copy(const DPrimitive_gco_3_dict_string_gco & self, obj<AAllocator> mm) noexcept;
// non-const methods
/** copy instance using allocator **/
static Opaque shallow_copy(DPrimitive_gco_3_dict_string_gco & self, obj<AAllocator> mm) noexcept;
/** during GC: forward immdiate children **/
static size_type forward_children(DPrimitive_gco_3_dict_string_gco & self, obj<ACollector> gc) noexcept;
///@}

View file

@ -22,11 +22,10 @@ namespace xo {
}
auto
IGCObject_DPrimitive_gco_0::shallow_copy(const DPrimitive_gco_0 & self, obj<AAllocator> mm) noexcept -> Opaque
IGCObject_DPrimitive_gco_0::shallow_copy(DPrimitive_gco_0 & self, obj<AAllocator> mm) noexcept -> Opaque
{
return self.shallow_copy(mm);
}
auto
IGCObject_DPrimitive_gco_0::forward_children(DPrimitive_gco_0 & self, obj<ACollector> gc) noexcept -> size_type
{

View file

@ -22,11 +22,10 @@ namespace xo {
}
auto
IGCObject_DPrimitive_gco_1_gco::shallow_copy(const DPrimitive_gco_1_gco & self, obj<AAllocator> mm) noexcept -> Opaque
IGCObject_DPrimitive_gco_1_gco::shallow_copy(DPrimitive_gco_1_gco & self, obj<AAllocator> mm) noexcept -> Opaque
{
return self.shallow_copy(mm);
}
auto
IGCObject_DPrimitive_gco_1_gco::forward_children(DPrimitive_gco_1_gco & self, obj<ACollector> gc) noexcept -> size_type
{

View file

@ -22,11 +22,10 @@ namespace xo {
}
auto
IGCObject_DPrimitive_gco_2_dict_string::shallow_copy(const DPrimitive_gco_2_dict_string & self, obj<AAllocator> mm) noexcept -> Opaque
IGCObject_DPrimitive_gco_2_dict_string::shallow_copy(DPrimitive_gco_2_dict_string & self, obj<AAllocator> mm) noexcept -> Opaque
{
return self.shallow_copy(mm);
}
auto
IGCObject_DPrimitive_gco_2_dict_string::forward_children(DPrimitive_gco_2_dict_string & self, obj<ACollector> gc) noexcept -> size_type
{

View file

@ -22,11 +22,10 @@ namespace xo {
}
auto
IGCObject_DPrimitive_gco_2_gco_gco::shallow_copy(const DPrimitive_gco_2_gco_gco & self, obj<AAllocator> mm) noexcept -> Opaque
IGCObject_DPrimitive_gco_2_gco_gco::shallow_copy(DPrimitive_gco_2_gco_gco & self, obj<AAllocator> mm) noexcept -> Opaque
{
return self.shallow_copy(mm);
}
auto
IGCObject_DPrimitive_gco_2_gco_gco::forward_children(DPrimitive_gco_2_gco_gco & self, obj<ACollector> gc) noexcept -> size_type
{

View file

@ -22,11 +22,10 @@ namespace xo {
}
auto
IGCObject_DPrimitive_gco_3_dict_string_gco::shallow_copy(const DPrimitive_gco_3_dict_string_gco & self, obj<AAllocator> mm) noexcept -> Opaque
IGCObject_DPrimitive_gco_3_dict_string_gco::shallow_copy(DPrimitive_gco_3_dict_string_gco & self, obj<AAllocator> mm) noexcept -> Opaque
{
return self.shallow_copy(mm);
}
auto
IGCObject_DPrimitive_gco_3_dict_string_gco::forward_children(DPrimitive_gco_3_dict_string_gco & self, obj<ACollector> gc) noexcept -> size_type
{