Updated comment.

This commit is contained in:
Alan Jeffrey 2017-01-04 15:22:46 +00:00
parent 67bf23016e
commit ef50a64598

View file

@ -1453,7 +1453,10 @@ impl Window {
pub fn freeze(&self) {
self.upcast::<GlobalScope>().suspend();
// A hint to the JS runtime that now would be a good time to GC this window.
// A hint to the JS runtime that now would be a good time to
// GC any unreachable objects generated by user script,
// or unattached DOM nodes. Attached DOM nodes can't be GCd yet,
// as the document might be thawed later.
self.Gc();
}