[PD] bang vs empty list

IOhannes m zmoelnig zmoelnig at iem.at
Mon Mar 4 09:24:06 CET 2013


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 2013-03-01 18:03, Ivica Bukvic wrote:
> This makes perfect sense. However, I have at least a couple of
> patches where I have a select connected to a networked stream of
> messages one which includes bang. So after I have to appied
> IOhannes' patch, this effectively resulted in a regression where
> bang messages were not recognized by the select object, throwing a
> large number of errors. While one can argue that this is simply a
> poorly designed patch the other side of the coin is to say that
> this latest addition has caused a breakage in the existing patches
> as this problem was never reported by pd before and now is causing
> xruns. I also hear your call for consistency so I am open for going
> either way particularly because the example you gave did not use
> select. After all what follows from select is nothing more than a
> bang while symbol bang would be intercepted anyways.

thanks for the test.
however, i'm not entirely sure whether this is really a regression (or
a poorly designed patch).

my patch will make empty lists do something meaningful (that is: check
whether the object can handle them) rather than simply ignore them,
but that was the point of the patch.

before my patch, [select] would emit a "no method for 'bang'" whenever
it received a [bang(, and it would do nothing when it received a
[list( (neither "accept" nor "reject" the message through it's
designated outlets).
now it will emit a "no method for 'list'" whenever it gets a [list(,
and retain the original behaviour for all other messages. this is the
intended behaviour.

i tried to reproduce your test-case, but it seems to behave
differently on pd-vanilla than on pd-l2ork. this is what i tried:

          [connect localhost 7777(
[r data]  |
|         |
+---------+
|
[netsend]

[netreceive 7777]
|
[select]

doing a [;data send bang( will give me a "select: no method for
'bang'" both with and without my patch applied.
doing a [;data send( will give me nothing both with and without my
patch applied (since [netsend] will not send an empty message).

could this be a regression in [dsis_netsend]/[dsis_netreceive] that
has been exposed by my patch?

maybe it would help if you posted a patch that exposes the problem.

fgmasdr
IOhannes
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.12 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iEYEARECAAYFAlE0WiMACgkQkX2Xpv6ydvRsxwCg8vxkb3JB4SKisMki5J5twdPD
K98AoIEsBMLZ1KNrUvhDZfTuYaHEgu+M
=Sr1k
-----END PGP SIGNATURE-----



More information about the Pd-list mailing list