<div dir="ltr"><div>I guess this is a consequence of the incompability of certain types, making code like this generate compile errors:</div><div><br></div><div>now $ float => float timeInSamples;<br></div><div><br></div>
<div>error: invalid cast to 'float' from 'time'...</div><div><br></div><div>Same thing with this:</div><div><br></div><div><div>10 => int i;</div><div>i $ dur=> dur delay;</div></div><div><br></div><div>
A curious thing is that it seems that boolean treatment seems to have been given a separate implementation for time/dur. </div><div><br></div><div>/Stefan<br><br><div class="gmail_quote">On Thu, Jul 24, 2008 at 8:35 AM, Kassen <<a href="mailto:signal.automatique@gmail.com">signal.automatique@gmail.com</a>> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;"><div dir="ltr">Dear list,<br><br>Considering that this is valid;<br><br>if (now) <<<"yay">>>;<br>
if (second) <<<"hurray">>>;<br><br>I feel that this should be valid as well;<br>
<br>if (now && true) <<<"this won't parse">>>;<br><br>However, it isn't; ChucK complains the "&&" operator can't be resolved on time and int. This is a issue as well;<br>
<br>if (second && true) <<<"This neither">>>;<br><br>of course we could go...<br>if (second) if (now) if (true) <<<"this is silly but runs">>>;<br><br>...but that looks a bit primitive.<br>
<br>Yours,<br>Kas.<br></div>
<br>_______________________________________________<br>
chuck-users mailing list<br>
<a href="mailto:chuck-users@lists.cs.princeton.edu">chuck-users@lists.cs.princeton.edu</a><br>
<a href="https://lists.cs.princeton.edu/mailman/listinfo/chuck-users" target="_blank">https://lists.cs.princeton.edu/mailman/listinfo/chuck-users</a><br>
<br></blockquote></div><br><br clear="all"><br>-- <br>Release me, insect, or I will destroy the Cosmos!
</div></div>