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.h11
1 files changed, 5 insertions, 6 deletions
diff --git a/js/src/jsscriptinlines.h b/js/src/jsscriptinlines.h
index 65abb5cb7..205a37f24 100644
--- a/js/src/jsscriptinlines.h
+++ b/js/src/jsscriptinlines.h
@@ -74,14 +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);
- RootedFunction fun(cx, self->function_);
- if (self->function_ && !JSFunction::getOrCreateScript(cx, fun))
+ RootedFunction fun(cx, script->function_);
+ if (script->function_ && !JSFunction::getOrCreateScript(cx, fun))
return nullptr;
- return self->function_;
+ return script->function_;
}
} // namespace js