A couple of ideas - abstract out the pop() interface, and have the object initialisable by a Tcl_Obj array as one of the many possible initialisations. Then we can store an array of variable objects.
Implemented by defining a << operator. Internals of TCL_arg redone such that the TCL reference counting is leveraged to share ownership of the TCL objects.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Implemented by defining a << operator. Internals of TCL_arg redone such that the TCL reference counting is leveraged to share ownership of the TCL objects.