[whatwg/streams] Permit freeing underlying source / sink / transformer after close (#932)

Once a stream is closed or errored, none of the methods on the underlying source / sink / transformer will be called any more. As a quality-of-implementation enhancement some browsers might decide to drop their references at that point so that the underlying object can be garbage collected even if the stream is still referenced.

This is currently a valid optimisation, however if someone adds weak refs to Javascript it will become observable.

I propose that we explicitly drop the references in the standard to ensure this optimisation is valid. Implementations still won't be required to drop the references because they're not required to perform GC at any particular time or on any particular object.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/whatwg/streams/issues/932

Received on Monday, 18 June 2018 06:19:10 UTC