Just noticed this in another thread:
As if on cue: A question popped up that falls outside of the streaming paradigm: https://forum.pdpatchrepo.info/topic/13269/splitting-variable-lists-based-on-symbol
IMO that user is just begging for a simple dictionary in Pd.
I've been working in HTML5 lately, so when I see this which is ad-hoc and annoying to parse in Pd:
ps 0 fft -1 -2 hip 5 0.4 9,3;
fft 0 1 hip 0 1 2;
I immediately see the desire for this kind of data structure:
{ps: 0, fft: [-1, -2], hip: [5, 0.4, 9,3]};
{fft: [0, 1], hip: [0, 1, 2]};
Immediately, you see that just throwing a Javascript object in there is way too rich for Pd-- even for this simple example I've got anonymous arrays and curly brackets. It would be quite a task to add JS objects or JSON objects as a primitive type in Pd.
So the question is-- what would Pd-style key/value pairs look like? What would it feel like to use them?
If someone has a good answer that gets me excited I'll write it as an idea for Purr Data GSoC this year. The only related area I can think of are data structures, but they tend to be too clunky and complicated for most users.
Edit: Even the puredata.info syntax highlighter is hinting at the hidden structure in that flat list!
					
									

 their associations are already cached by the time a symbol becomes part of a message. So the cost of forwarding a message to a receiver is just the cost of message evaluation plus the cost of invoking the relevant receiver's function in pd_typedmess. Since the user obviously knows how many arguments each receiver expects, they can skip iterating over the args in order to forward the next message. No lookups or data copying is needed.
									
									
									
									

