Here's what you might try (node v0.10.x):
// in globals
static Persistent<String> data_symbol;
static Persistent<String> tag_symbol;
// in addon initialization function
data_symbol = NODE_PSYMBOL("data");
tag_symbol = NODE_PSYMBOL("tag");
// in some function somewhere
HandleScope scope;
Local<Array> nodes = Array::New();
for (unsigned int i = 0; i < elems.length; ++i) {
HandleScope scope;
Local<Object> node_obj = Object::New();
node_obj->Set(data_symbol, String::New(elems[i].data.c_str()));
node_obj->Set(tag_symbol, Integer::New(elems[i].tag));
nodes->Set(i, node_obj);
}
return scope.Close(nodes);