Firefox 3, Now With Array Inconsistency

Alex Russell has pointed out that Firefox 3 has some quirky issues with JavaScript arrays, namely, an array made from a literal has a different constructor than an array made from instantiating the global array object. Long story short, the below is true:

[].constructor != new Array().constructor

Update

It seems like this is a Firebug-specific issue. If you try to evaluate the above in Error Console, you'll get false.

Trackback URL for this post:

http://kourge.net/trackback/111

Post new comment

The content of this field is kept private and will not be shown publicly.
  • Web page addresses and e-mail addresses turn into links automatically.
  • Allowed HTML tags: <a> <em> <strong> <cite> <code> <ul> <ol> <li> <dl> <dt> <dd>
  • Lines and paragraphs break automatically.

More information about formatting options