[PD] '$0' in messages again, another proposal? (Was: Pd 0.52 test 2 is out)

Antoine Rousseau antoine at metalu.net
Thu Dec 2 10:59:19 CET 2021


>
> - *$0 is not a creation argument after all, i.e. it is not part of
> "ce_argv".*


I don't know... Can't we consider $0 as an "unconditional" creation
argument?...

* Also, it really **has a different purpose. (...) $0 would be a special
> case either way.*
>

I'm not sure either. To me, both $0 and $1 etc. can be used to identify an
instance of an abstraction.
IMO $0 is the quick way, but has the limitation to make it (nearly)
impossible to access members from the outside.
That's why it often happened to me to rename an instance [myAbs] to e.g
[myAbs myabs1], then to replace $0 in [myAbs] with $1, so I can easily
access [myAbs]'s members from the parent - from anywhere in fact (Actually,
nowadays I tend to use as few $0 as possible).
If we could use $0 in messages, then the last operation would be more
complicated (cause you couldn't simply substitute $0 with e.g $1).
So I think it's better to keep the $0/$n symmetry.

I think having a "message" object is a better idea [than $$'s one]
>

What I like with the $$ idea, is that it would provide a simple way to
merge creation arguments with variable arguments, i.e compose a message
with both the abstraction arguments and the incoming message elements.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.puredata.info/pipermail/pd-list/attachments/20211202/3cf8a441/attachment.htm>


More information about the Pd-list mailing list