mirror of
https://repo.dactyloidae.xyz/Dactyloidae/UXP.git
synced 2026-09-04 14:58:37 +09:00
Issue #2083 - Part 1: Make RegExpShared a GC thing.
Based on Mozilla bug 1345177. Changes from the original bug's patch: - We don't have JS::CurrentThreadIsHeapCollecting, so let's use trc->runtime()->isHeapCollecting() instead. - Mozilla bug 1337117 renamed runtimeFromMainThread to runtimeFromActiveCooperatingThread for Firefox 54, so let's use the former
This commit is contained in:
parent
8bf892d728
commit
3796c7c1e1
29 changed files with 384 additions and 412 deletions
|
|
@ -6144,7 +6144,7 @@ JS_GetRegExpFlags(JSContext* cx, HandleObject obj)
|
|||
RegExpGuard shared(cx);
|
||||
if (!RegExpToShared(cx, obj, &shared))
|
||||
return false;
|
||||
return shared.re()->getFlags();
|
||||
return shared->getFlags();
|
||||
}
|
||||
|
||||
JS_PUBLIC_API(JSString*)
|
||||
|
|
@ -6156,7 +6156,7 @@ JS_GetRegExpSource(JSContext* cx, HandleObject obj)
|
|||
RegExpGuard shared(cx);
|
||||
if (!RegExpToShared(cx, obj, &shared))
|
||||
return nullptr;
|
||||
return shared.re()->getSource();
|
||||
return shared->getSource();
|
||||
}
|
||||
|
||||
/************************************************************************/
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue