зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1661079 - Part 14: Use JSRuntime* parameter in ParserAtomsTable and CompilationStencil. r=tcampbell
Differential Revision: https://phabricator.services.mozilla.com/D88352
This commit is contained in:
Родитель
10e0c8c80f
Коммит
35dc53c431
|
@ -222,7 +222,7 @@ struct CompilationStencil {
|
|||
// Table of parser atoms for this compilation.
|
||||
ParserAtomsTable parserAtoms;
|
||||
|
||||
explicit CompilationStencil(JSContext* cx) : parserAtoms(cx) {}
|
||||
explicit CompilationStencil(JSRuntime* rt) : parserAtoms(rt) {}
|
||||
|
||||
#if defined(DEBUG) || defined(JS_JITSPEW)
|
||||
void dump();
|
||||
|
@ -362,7 +362,7 @@ struct CompilationInfo {
|
|||
|
||||
// Construct a CompilationInfo
|
||||
CompilationInfo(JSContext* cx, const JS::ReadOnlyCompileOptions& options)
|
||||
: cx(cx), input(options), stencil(cx) {}
|
||||
: cx(cx), input(options), stencil(cx->runtime()) {}
|
||||
|
||||
MOZ_MUST_USE bool instantiateStencils(CompilationGCOutput& gcOutput);
|
||||
|
||||
|
|
|
@ -184,8 +184,8 @@ void ParserAtomEntry::dumpCharsNoQuote(js::GenericPrinter& out) const {
|
|||
}
|
||||
#endif
|
||||
|
||||
ParserAtomsTable::ParserAtomsTable(JSContext* cx)
|
||||
: wellKnownTable_(*cx->runtime()->commonParserNames) {}
|
||||
ParserAtomsTable::ParserAtomsTable(JSRuntime* rt)
|
||||
: wellKnownTable_(*rt->commonParserNames) {}
|
||||
|
||||
JS::Result<const ParserAtom*, OOM&> ParserAtomsTable::addEntry(
|
||||
JSContext* cx, AddPtr& addPtr, UniquePtr<ParserAtomEntry> entry) {
|
||||
|
|
|
@ -412,7 +412,7 @@ class ParserAtomsTable {
|
|||
const WellKnownParserAtoms& wellKnownTable_;
|
||||
|
||||
public:
|
||||
explicit ParserAtomsTable(JSContext* cx);
|
||||
explicit ParserAtomsTable(JSRuntime* rt);
|
||||
|
||||
private:
|
||||
// Custom AddPtr for the ParserAtomsTable.
|
||||
|
|
Загрузка…
Ссылка в новой задаче