put list processing API in public interface
Suppose we have an external class "foo" which takes a single float input and produce a single output.
Now suppose the developer wants to revise "foo" so that it can handle lists. E.g., for a list of 5 floats it outputs a list of size 5.
- what kind of data structure does the developer use to build up the output list? An array would be fast but statically allocated to some small size. Automatic allocation on the stack is more flexible but more dangerous and not necessarily portable. Heap allocation is a good catchall but is not realtime safe.
- suppose the input list can be a mixture of floats and symbols. How then to handle anythings vs. lists? To convert an anything to a list you must allocate a container of size (argc + 1), put the selector at index 0, then put argv after that.
These problems are handled in x_list.c, but we need a public interface so that external devs can all use the same tools for processing lists. This is especially important because memory allocation in externals has a high probability of causing crasher bugs.