ECMAScript® 2024 Language Specification

Draft ECMA-262 / February 15, 2024

9.11 ClearKeptObjects ( )

The abstract operation ClearKeptObjects takes no arguments and returns unused. ECMAScript implementations are expected to call ClearKeptObjects when a synchronous sequence of ECMAScript executions completes. It performs the following steps when called:

  1. Let agentRecord be the surrounding agent's Agent Record.
  2. Set agentRecord.[[KeptAlive]] to a new empty List.
  3. Return unused.