OO languages are similar in many respects.

Apparently, (Tip 213, Anthony Porter, The best C++ Tips Ever, McGraw Hill)

when you increment 'a' and access it with ++a,
you increment 'a', and
use a reference to it.

but with a++, you
make a temporary copy of 'a'
increment the original and
return a copy of the temporary, not a reference it,
because the temporary object is destroyed.
That's the overhead.

Even passing objects back from functions involve the creation of temporary
objects.

I am right in thinking that p code is pseudo-code and therefore does not
indicate code bytes?

John


----- Original Message ----- 
From: "Steven Sacks | BLITZ" <[EMAIL PROTECTED]>
To: "Flashcoders mailing list" <flashcoders@chattyfig.figleaf.com>
Sent: Wednesday, September 20, 2006 12:07 AM
Subject: RE: [Flashcoders] Find item in array


> using a for..i..in loop will always be faster

It's been proven before here on flashcoders that for in is not faster
than --a -(-1) because it compiles to more lines of pcode.  I guess it's
time to use Flasm to bust out some pcode and post it here on the list
instead of making claims based on hunches and past posts in the
archives.

_______________________________________________
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


_______________________________________________
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com

Reply via email to