Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!think.com!snorkelwacker.mit.edu!stanford.edu!csli!csli.stanford.edu From: nash@csli.stanford.edu (Ron Nash) Newsgroups: comp.sys.mac.hypercard Subject: apparent bug in hc 2.0 Message-ID: <19967@csli.Stanford.EDU> Date: 16 Jun 91 21:57:00 GMT Sender: nash@csli.Stanford.EDU Organization: CSLI, Stanford University Lines: 24 The "repeat with" structure in hc 2.0 apprently prevents the programmer from modifying the value of the counter from within the loop. Try the following script: on mouseUp repeat with i = 1 to 5 put "top of loop: i = " & i wait 2 seconds if i > 1 then put i - 1 into i put "bottom of loop: i = " & i wait 2 seconds end repeat end mouseUp This "feature" is undocumented as far as I can tell. C programmers would call it a misfeature. At the very least, the hypertalk interpreter should complain about attempts to set read-only variables. (Just another unix guy too lazy to program the Mac in a real language. And paying the price). Ron Nash