W3C home > Mailing lists > Public > public-webapps@w3.org > January to March 2010

Re: Allow to return same NodeList object for queries like getElementsByTagName, getElementsByClassName and getElementsByName

From: Anton Muhin <antonm@chromium.org>
Date: Fri, 12 Feb 2010 14:31:27 +0300
Message-ID: <c42bef051002120331h72ad859fnd7977a7f0d4f064b@mail.gmail.com>
To: Anne van Kesteren <annevk@opera.com>
Cc: public-webapps@w3.org, Maciej Stachowiak <mjs@apple.com>
On Fri, Feb 12, 2010 at 2:19 PM, Anne van Kesteren <annevk@opera.com> wrote:
> On Fri, 22 Jan 2010 14:11:40 +0100, Anton Muhin <antonm@chromium.org> wrote:
>> Is it possible to allow caching for those cases?  Firefox caches those
>> node lists for a long time (Maciej found the related bug
>> https://bugzilla.mozilla.org/show_bug.cgi?id=140758).  IE8 caches as
>> well.   Opera, Safari and Chrome do not.
> Sorry for the somewhat late reply. We'd prefer not to change the
> specification here and keep the requirement. We're afraid of potential hard
> to detect incompatibility bugs if you sometimes cache and sometimes don't.
> We're also not convinced that you cannot get the performance win by other
> means.

I see.  One argument against potential bugs is both IE and FF do that,
so I won't expect lots of people relying on this behaviour anyway.

Regarding performance: if the spec mandates creation of new objects,
that's something which is difficult to optimize away.

thanks and yours,

> --
> Anne van Kesteren
> http://annevankesteren.nl/
Received on Friday, 12 February 2010 11:32:18 UTC

This archive was generated by hypermail 2.3.1 : Friday, 27 October 2017 07:26:22 UTC