Ugly fix for clang
This commit is contained in:
parent
f23eb282c0
commit
5dd08c6c71
@ -794,13 +794,16 @@ Handle<Value> FromConstructorTemplate(Persistent<FunctionTemplate>& t,
|
|||||||
HandleScope scope;
|
HandleScope scope;
|
||||||
|
|
||||||
const int argc = args.Length();
|
const int argc = args.Length();
|
||||||
Local<Value> argv[argc];
|
Local<Value>* argv = new Local<Value>[argc];
|
||||||
|
|
||||||
for (int i = 0; i < argc; ++i) {
|
for (int i = 0; i < argc; ++i) {
|
||||||
argv[i] = args[i];
|
argv[i] = args[i];
|
||||||
}
|
}
|
||||||
|
|
||||||
Local<Object> instance = t->GetFunction()->NewInstance(argc, argv);
|
Local<Object> instance = t->GetFunction()->NewInstance(argc, argv);
|
||||||
|
|
||||||
|
delete[] argv;
|
||||||
|
|
||||||
return scope.Close(instance);
|
return scope.Close(instance);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user