summaryrefslogtreecommitdiff
path: root/test/language/expressions/async-generator/throw-suspendedYield-try-finally-throw.js
diff options
context:
space:
mode:
Diffstat (limited to 'test/language/expressions/async-generator/throw-suspendedYield-try-finally-throw.js')
-rw-r--r--test/language/expressions/async-generator/throw-suspendedYield-try-finally-throw.js13
1 files changed, 12 insertions, 1 deletions
diff --git a/test/language/expressions/async-generator/throw-suspendedYield-try-finally-throw.js b/test/language/expressions/async-generator/throw-suspendedYield-try-finally-throw.js
index b7faf9cec..15088f8ff 100644
--- a/test/language/expressions/async-generator/throw-suspendedYield-try-finally-throw.js
+++ b/test/language/expressions/async-generator/throw-suspendedYield-try-finally-throw.js
@@ -3,12 +3,23 @@
/*---
author: Caitlin Potter <caitp@igalia.com>
-esid: pending
+esid: sec-asyncgenerator-prototype-throw
description: >
Thrown generator suspended in a yield position resumes execution within
the associated finally block and throws an error and suspendeds execution
again
info: |
+ AsyncGenerator.prototype.throw ( exception )
+ 1. Let generator be the this value.
+ 2. Let completion be Completion{[[Type]]: throw, [[Value]]: exception, [[Target]]: empty}.
+ 3. Return ! AsyncGeneratorEnqueue(generator, completion).
+
+ AsyncGeneratorEnqueue ( generator, completion )
+ ...
+ 8. If state is not "executing", then
+ a. Perform ! AsyncGeneratorResumeNext(generator).
+ ...
+
AsyncGeneratorResumeNext:
If completion.[[Type]] is throw, and generator.[[AsyncGeneratorState]] is
"suspendedYield", and generator is resumed within a try-block with an