mirror of
https://repo.dactyloidae.xyz/Dactyloidae/UXP.git
synced 2026-09-03 22:38:41 +09:00
Bug 1331092 - Part 2: Implement Async Generator except yield*.
Tag #1287
This commit is contained in:
parent
c8d569d1b8
commit
10b93afff4
23 changed files with 1015 additions and 55 deletions
|
|
@ -70,6 +70,7 @@
|
|||
#include "js/StructuredClone.h"
|
||||
#include "js/Utility.h"
|
||||
#include "vm/AsyncFunction.h"
|
||||
#include "vm/AsyncIteration.h"
|
||||
#include "vm/DateObject.h"
|
||||
#include "vm/Debugger.h"
|
||||
#include "vm/EnvironmentObject.h"
|
||||
|
|
@ -3591,6 +3592,11 @@ CloneFunctionObject(JSContext* cx, HandleObject funobj, HandleObject env, Handle
|
|||
return nullptr;
|
||||
}
|
||||
|
||||
if (IsWrappedAsyncGenerator(fun)) {
|
||||
JS_ReportErrorNumberASCII(cx, GetErrorMessage, nullptr, JSMSG_CANT_CLONE_OBJECT);
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
if (CanReuseScriptForClone(cx->compartment(), fun, env)) {
|
||||
// If the script is to be reused, either the script can already handle
|
||||
// non-syntactic scopes, or there is only the standard global lexical
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue