summaryrefslogtreecommitdiffstats
path: root/js/src/jsscriptinlines.h
diff options
context:
space:
mode:
Diffstat (limited to 'js/src/jsscriptinlines.h')
-rw-r--r--js/src/jsscriptinlines.h12
1 files changed, 6 insertions, 6 deletions
diff --git a/js/src/jsscriptinlines.h b/js/src/jsscriptinlines.h
index da23804ac..e1052111b 100644
--- a/js/src/jsscriptinlines.h
+++ b/js/src/jsscriptinlines.h
@@ -74,13 +74,13 @@ void
SetFrameArgumentsObject(JSContext* cx, AbstractFramePtr frame,
HandleScript script, JSObject* argsobj);
-inline JSFunction*
-LazyScript::functionDelazifying(JSContext* cx) const
+/* static */ inline JSFunction*
+LazyScript::functionDelazifying(JSContext* cx, Handle<LazyScript*> script)
{
- Rooted<const LazyScript*> self(cx, this);
- if (self->function_ && !self->function_->getOrCreateScript(cx))
+ RootedFunction fun(cx, script->function_);
+ if (script->function_ && !JSFunction::getOrCreateScript(cx, fun))
return nullptr;
- return self->function_;
+ return script->function_;
}
} // namespace js
@@ -100,7 +100,7 @@ JSScript::functionDelazifying() const
}
inline void
-JSScript::ensureNonLazyCanonicalFunction(JSContext* cx)
+JSScript::ensureNonLazyCanonicalFunction()
{
// Infallibly delazify the canonical script.
JSFunction* fun = function();