Hallo, Jonathan Wilkes hat gesagt: // Jonathan Wilkes wrote:
Actually [list $1 $2 $3 $4 $5] seems to work in this context, but I guess that's because the first arg isn't a symbol. Is that why you're saying [list append] is needed?
The [list] object will behave differently depending on its first argument: You get to choose between [list prepend], [list append], [list split] etc. The following arguments have different meanings depending on the first argument.
E.g. [list split 3] will split a list at position 3, while [list prepend 3] will add a "3" in front of your incoming list.
If you create [list] without any argument it will be the same as [list append], but if you'd use [list $1] then the value of $1 will decide, which kind of list operation you get. So if $1 is "split" you get a splitter, if it's "append" then you get a [list append].
So [list $1 $2 $3 $4 $5] is *not* the same as [list append $1 $2 $3 $4 $5]! Try it by sending something into both and print the result.
Frank