Change waitUntil behavior; use reference count approach for extension (#1049)
(1) This removes the extendable event's extensions allowed flag and
introduces a reference count based approach instead of the
promise-copying-and-checking approach.
(2) This extends the opportunities of the lifetime extension by allowing
waitUntil() in the task queued by the reaction to the given promise.
Fixes #931 #935 #1039 #1050.