Browse Source

Ugly fix for clang

v0.7.4-release
Ryan Dahl 14 years ago
parent
commit
5dd08c6c71
  1. 5
      src/node.cc

5
src/node.cc

@ -794,13 +794,16 @@ Handle<Value> FromConstructorTemplate(Persistent<FunctionTemplate>& t,
HandleScope scope;
const int argc = args.Length();
Local<Value> argv[argc];
Local<Value>* argv = new Local<Value>[argc];
for (int i = 0; i < argc; ++i) {
argv[i] = args[i];
}
Local<Object> instance = t->GetFunction()->NewInstance(argc, argv);
delete[] argv;
return scope.Close(instance);
}

Loading…
Cancel
Save