[PD-dev] First attempt at "list" object uploaded

Hans-Christoph Steiner hans at eds.org
Mon Jul 25 18:23:05 CEST 2005


On Jul 25, 2005, at 8:23 AM, Frank Barknecht wrote:

> Hallo,
> Guenter Geiger hat gesagt: // Guenter Geiger wrote:
>
>> Let me explain:
>> In order to convert lists to messages I normally use message boxes  
>> with
>> $ arguments. E.g if I send a list "foo 2" to  [set $1 $2( it will
>> construct a message that reads [set foo 2(,
>> similar with a 3 element list and $1,$2,$3.
>> Now, my proposal is to introduce a $@ dollar symbol which accepts
>> lists of any length, this way it is not necessary to know the
>> length of a list before converting it into a message.
>
> However with the new list processing objects the need to to use
> something like $@ will show up much less often because [list prepend
> set]---[list trim] would be the same as [set $@( in almost every case.
> The only exception I can think of currently are "send"-messages, i.e.
> those starting with ";". Still I agree, that $@ would be a useful
> feature, let alone to save some typing: [set $@( is much shorter than
> [set $1 $2 $3 $4 $5 $6 $7 $8 $9 $10 $11 $12 $13 $14 $15 $16 $17 $18(
>

But [set $@( and [set $1 $2 $3 $4 $5 $6 $7 $8 $9 $10 $11 $12 $13 $14  
$15 $16 $17 $18(
  would produce different results since the message's unused dollar args  
would be initialized to 0.

[one two three(
|
[set $1 $2 $3 $4 $5 $6 $7 $8 $9 $10 $11 $12 $13 $14 $15 $16 $17 $18(
|
[one two three 0 0 0 0 0 0 0 0 0 0 0 0 0 0(

While $@ should do this:

[one two three(
|
[set $@(
|
[one two three(

.hc


>
> Ciao
> --  
>  Frank Barknecht                               _ ______footils.org__
>
>           _ __latest track: "plak" @ http://footils.org/cms/show/44
>
> _______________________________________________
> PD-dev mailing list
> PD-dev at iem.at
> http://lists.puredata.info/listinfo/pd-dev
>

________________________________________________________________________ 
____

            "The arc of history bends towards justice."
                                            - Dr. Martin Luther King, Jr.





More information about the Pd-dev mailing list