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

Re: File API "oneTimeOnly" is too poorly defined

From: Glenn Maynard <glenn@zewt.org>
Date: Thu, 29 Mar 2012 22:40:49 -0500
Message-ID: <CABirCh_LibMM+8s96G3=pAne83znP-b5Aua57B_rKVwxnbWm+Q@mail.gmail.com>
To: Bronislav Klučka <Bronislav.Klucka@bauglir.com>
Cc: public-webapps@w3.org
2012/3/29 Bronislav Klučka <Bronislav.Klucka@bauglir.com>

> Sure, weak referencing is probably not well explored approach, but the
> underlying idea applied to blob is interesting: URL creates no reference to
> Blob (from GC perspective), meaning Blob is subjected to GC regardless of
> BlobUrl existence. This would remove the need for revoking URL, programmers
> would only need to maintain blobs they want to be persistent (e.g. in some
> global array).
>

Weak referencing is pretty well explored, I think.  It's intentionally not
supported for the most part in JavaScript, because most weakref features
expose garbage collection behavior to scripts.  Web APIs don't do that.

This approach exposes GC behavior, making it possible to write code that
behaves differently depending on GC.

-- 
Glenn Maynard
Received on Friday, 30 March 2012 03:41:18 GMT

This archive was generated by hypermail 2.3.1 : Tuesday, 26 March 2013 18:49:50 GMT