Fix the init() function in Heap::FunctionObject
One of the overloads took a QV4::Function * and was so far
apparently unused (as it couldn't have worked since change
3b14e2ffdd
). Fix it since
it's getting some use again in the next change.
Change-Id: I3eabb332f9e3f2262a5710d43016346b7138f7e7
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
This commit is contained in:
parent
91ac4a8d09
commit
ef90db10a8
|
@ -81,7 +81,8 @@ void Heap::FunctionObject::init(QV4::ExecutionContext *scope, QV4::String *name,
|
|||
void Heap::FunctionObject::init(QV4::ExecutionContext *scope, Function *function, bool createProto)
|
||||
{
|
||||
Object::init();
|
||||
function = nullptr;
|
||||
this->function = function;
|
||||
function->compilationUnit->addref();
|
||||
this->scope = scope->d();
|
||||
Scope s(scope->engine());
|
||||
ScopedString name(s, function->name());
|
||||
|
|
Loading…
Reference in New Issue