[Laszlo-dev] Any idea what this person is asking? Is pop()
supposed to be defined by ECMAScript on associative arrays?
Neil Mix
nmix at savagebeast.com
Wed Jun 29 14:09:09 PDT 2005
I've never seen a JS implementation that allowed pop() on regular
objects. I can't even imagine how that would work -- how would you
define ordering? FIFO? Alpha?
He might be confused about the fact that using a string as an index on
an Array object treats it like an object property rather than an Array
element. That's a very good thing -- otherwise you wouldn't be able to
extend the Array class -- additional methods would show up as array
elements. (Also a reason why using for(x in y) to iterate through
array elements is a really bad idea. but I digress.)
I've always thought that JS's treatment of Arrays is confusing until
you've truly grokked how Objects work in the language.
On Jun 29, 2005, at 1:46 PM, Henry Minsky wrote:
> http://www.laszlosystems.com/developers/community/forums/
> showthread.php?threadid=3337
>
>
> --
> Henry Minsky
> Software Architect
> hminsky at laszlosystems.com
>
> _______________________________________________
> Laszlo-dev mailing list
> Laszlo-dev at openlaszlo.org
> http://www.openlaszlo.org/mailman/listinfo/laszlo-dev
>
More information about the Laszlo-dev
mailing list