> A variable is always passed as a reference and not a copy. That's not true. A primitive value like a Number is passed as a copy, not a reference. - Gordon
________________________________ From: [email protected] [mailto:[EMAIL PROTECTED] On Behalf Of Kevin Aebig Sent: Friday, February 29, 2008 7:30 AM To: [email protected] Subject: RE: [flexcoders] A Hole in ActionScript 3.0, and a Way Around It This has been the case with Actionscript since the beginning. A variable is always passed as a reference and not a copy. So each time you're looping over and creating the function, you're only passing a reference to the variable, and not the value itself. !k ________________________________ From: [email protected] [mailto:[EMAIL PROTECTED] On Behalf Of Ed Smith Sent: Thursday, February 28, 2008 7:20 PM To: [email protected] Subject: [flexcoders] A Hole in ActionScript 3.0, and a Way Around It I've just written an article about what I consider to be a rather ugly behavior in ActionScript 3.0: http://effectgenerator.com/blog/?p=8 <http://effectgenerator.com/blog/?p=8> I appreciate that other coders may not see this as a bug per se, but if there is sufficient agreement then maybe a change to the compiler could be made (or at least a warning added?). It's certainly bitten me several times during coding. I'd appreciate your comments. Many Thanks, Ed

