Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Editorial: rigorize tasks and task queuing
This introduces tasks as a proper struct, with well-defined fields, and makes "queue a task" and "queue a microtask" into more well-defined algorithms for setting up and queuing those tasks. It centralizes and calls out the still-somewhat-vague parts in the "implied event loop" and "implied document" definitions. Other minor cleanups and clarifications: * Fixes "performing a microtask checkpoint" to be a boolean; previously it was referred to as a flag but set to true or false. * Fixes #4242 by making it clearer how tasks are chosen by the event loop. * Adds more guidance text around how task sources and task queues interact. * Introduces a new subsection "Queuing tasks" to contain the task-queuing definitions, which were previously spread out through "Definitions" (for non-microtask tasks) and "Processing model" (for microtasks). * Centralizes all properties of the event loop into "Definitions". They were previously spread out throughout "Definitions" and "Processing model".
- Loading branch information