[PD] definitions of data types

Hans-Christoph Steiner hans at eds.org
Mon Feb 6 22:16:24 CET 2006


On Feb 6, 2006, at 3:06 PM, IOhannes m zmoelnig wrote:

> Hans-Christoph Steiner wrote:
>>>
>>> right.
>>> nobody said that "word" is a symbol.
>>>
>>> but nevermind...
>>
>>
>> Actually, you are wrong, and that is one of the key problems I am
>
>> arguments.  It quite clearly says "The selector is a symbol", but  
>> these
>
> [...]
>
>
>>
>>
>> First, the PdDefinitions page isn't meant to learn from, but instead
>> for us to work out the details of this issue.  Second, I agree, things
>
> yes, but if we can make it clear for us (so we can talk about it) then
> chances are high that things are so clear that others can learn from  
> it.

Absolutely.  But first let's figure out all the details, then come up  
with clear definitions, then teach people them.

>> That's what the docs say, but that is not what [select], [route], and
>> [trigger] say.  We need to document what is actually happening, not
>> follow the docs and ignore what is actually happening.
>>
>> The 3rd argument of that list is only a symbol if it has a "list" or
>> "symbol" selector.  Consider this patch:
>>
>> [list 1 two drei(
>> |
>> [list split 2]
>>       |
>>       [list trim]
>>
>> The output of [list trim] is not a symbol.  [symbol drei( is a symbol,
>> [list drei( is a symbol.  [drei( is not a symbol.
>
> so the basic confusion comes from the fact that there are 2 different
> kinds of symbol:
> a) the atom-type symbol
> b) the message-type symbol
>
> ad a: "drei" is always symbol, even if it is a selector; "symbol drei"
> consists of 2 symbols, one is "symbol", the other one "drei".
> symbols of that kind are always stored within a hash-table and are
> produced with gensym() (on the C side of things)
> the message-selector is _always_ of atom-type symbol.
>
> ad b: a symbol-message is a message with a selector "symbol" and  
> exactly
> one argument of type symbol.

One of the big problems is that symbol messages and symbolic atoms are  
both called "symbols", yet then behave very differently.  So it would  
be very helpful to use different words here, like "symbolic atom",  
"numeric atom", "pointer atom".  Then a "symbol" and "float" are purely  
message types.  So then you can rephrase the above:

"drei" is always a symbolic atom, even if it is a selector.  "symbol  
drei" consists of two symbolic atoms, "symbol" and "drei".  symbolic  
atoms of that kind are always stored within a hash-table and are  
produced with gensym().  The message selector is always a symbolic  
atom.

And that would be clearer...  its a start...

I have switched up the PdDefinitions wiki.  On the main page, its just  
documentation of all of the various categories (data types is not the  
right word, so I changed to categories).  Plus there is documentation  
of the of a number of specific details.  Please add anything that you  
find.  Plus, at the bottom are separate pages for Frank's and my  
attempts at definitions.  Feel free to add your own.

.hc


>>> and don't forget "pointer element".
>>
>>
>> I think that bangs and pointers are clearly defined, I feel no need to
>> try to redefine them.
>
> i thought "definitions of data types" would define everything.
>
>>
>>> apropos, isn't "element" a synonym for "atom"?
>>
>>
>> An atom is a float or a symbol, right?.   [word( is not float or a
>
> wrong (as i read it): an atom is a float or a symbol or a pointer.
>
>> symbol, so it is therefore not an atom.  But it is an element in a
>> message, in this case, its used as a selector.  And from what I see,
>> "atom" is not a useful distinction when you view things from Pd.
>> Instead, it is part of the implementation.
>
> i think the implementation tries to reflect the design.
> however, i am very used to reading pd in C, so my view might be narrow.
>
>>
>> http://crca.ucsd.edu/~msp/Pd_documentation/x2.htm#s1.2
>>
>> "The text is divided into  atoms  separated by white space."
>> "Atoms are either numbers or symbols..."
>>
>> By the first definition, atoms and elements are the same thing.  But
>> not according to the second.
>
> this quote refers to "text".
> a message need not necessarily be writeable as text.
> (of course it makes everything (esp. documentation) much easier, if you
> can write down the message).
>
>
> mfg.a.dr
> IOhannes
>

________________________________________________________________________ 
____

"[W]e have invented the technology to eliminate scarcity, but we are  
deliberately throwing it away to benefit those who profit from  
scarcity."
                                                      -John Gilmore





More information about the Pd-list mailing list