[PD] expr alternative

Jonathan Wilkes jancsika at yahoo.com
Tue Oct 25 23:02:41 CEST 2011

----- Original Message -----
> From: Mathieu Bouchard <matju at artengine.ca>
> To: Jonathan Wilkes <jancsika at yahoo.com>
> Cc: Hans-Christoph Steiner <hans at at.or.at>; Max <abonnements at revolwear.com>; PD list <pd-list at iem.at>; Shahrokh Yadegari <sdy at ucsd.edu>
> Sent: Tuesday, October 25, 2011 3:47 PM
> Subject: Re: [PD] expr alternative
> Le 2011-10-25 à 12:38:00, Jonathan Wilkes a écrit :
>>  It's worth noting that the current [expr] is both 
> "Max-centric"-- because numbers written as integers imply integer 
> math-- and incompatible with Max-- because in object boxes Pd strips the decimal 
> from "1." which is a common idiom in Max to force float math.
> Pd also turns «1.0» (and such) into «1».
> However, Pd never strips those things if they get parsed as symbols.
> thus [expr 1.0/2] gives 0.5 whereas [expr 1.0 /2] will become [expr 1 /2] which 
> will give 0.

Right, but that punishes the Pd users by making them use Max notation to force 
floating point math, and it confuses the Max users coming to (or porting patches 
to) Pd, who learn Pd's float-centrism then are forced to relearn some 
bizarro version of Max number types where spaces matter.

But I wouldn't call that a bug because I can't remember if [expr] claims to be 
Max-compatible or not.


> ______________________________________________________________________
> | Mathieu BOUCHARD ----- téléphone : +1.514.383.3801 ----- Montréal, QC

More information about the Pd-list mailing list