- From: Jonas Sicking <jonas@sicking.cc>
- Date: Fri, 4 Sep 2009 18:03:35 -0400
On Thu, Sep 3, 2009 at 7:41 AM, Ian Hickson<ian at hixie.ch> wrote: > On Mon, 31 Aug 2009, Jonas Sicking wrote: >> > >> > Upon further consideration I've renamed getStorageUpdates() to >> > yieldForStorageUpdates(). >> >> 'yield' usually refers to halting execution. I would expect the above >> name to stop the current thread and allow other threads to run. While >> that is what could be happening here, I'm not sure that is the primary >> function of the call. > > It's more or less exactly what the method does, no? I think the common case is that no other thread is blocked, and we'll simply drop the lock on the storage mutex and continue execution of the current thread. Compare this to the Javascript 1.8 keyword 'yield', which always stops execution of the currently running code. Granted, Javascript 1.8 is Firefox only at this point, however I think the hope is that it'll get implemented across more browsers eventually. >> I really liked Darin's (?) suggestion of allowStorageUpdates as that >> seems to exactly describe the intended use of the function. We no longer >> prevent other page from updating the storage. > > "allow" implies a state change, which I don't think really matches what is > happening here. ("How do I disallow updates?") I don't understand why you associate "allow" with "state change"? It could just as well be allowing anything else. The word "Updates" is much more associated with "state change" i'd say. And that word occurs in your proposal too. Really it should probably be allowStorageAccess or yeildForStorageAccess to be more correct. / Jonas
Received on Friday, 4 September 2009 15:03:35 UTC