Background: A binding map stores values in subclasses of BoundValue. The StructureValue is used to store the bound value of a structured object such as (vec3 1 2 3). The copy_structure method of StructureValue copies the code of a structure into and out of an AERA object such as (mk.val h postition (vec3 1 2 3)) .
We want to support a bound value of a "nested" structure object such as (vec [1 2 3]), where the (vec :) is the top structure and the array [1 2 3] is the sub structure. This pull request updates copy_structure to check if part of the structure is an I_PTR which points to a sub structure. If so, then it calls itself recursively to copy the sub structure (and any further sub-structures). There is no change of behavior for existing AERA examples where no bound structured objects have sub-structures.
Background: A binding map stores values in subclasses of
BoundValue
. TheStructureValue
is used to store the bound value of a structured object such as(vec3 1 2 3)
. Thecopy_structure
method ofStructureValue
copies the code of a structure into and out of an AERA object such as(mk.val h postition (vec3 1 2 3))
.We want to support a bound value of a "nested" structure object such as
(vec [1 2 3])
, where the(vec :)
is the top structure and the array[1 2 3]
is the sub structure. This pull request updatescopy_structure
to check if part of the structure is an I_PTR which points to a sub structure. If so, then it calls itself recursively to copy the sub structure (and any further sub-structures). There is no change of behavior for existing AERA examples where no bound structured objects have sub-structures.