mirror of https://github.com/nodejs/node.git
19 lines
500 B
JavaScript
19 lines
500 B
JavaScript
|
var assert = require('assert');
|
||
|
var binding = require('./out/Release/binding');
|
||
|
|
||
|
console.log("binding.length =", binding.length);
|
||
|
|
||
|
if (process.tid === 1) {
|
||
|
var isolate = process._newIsolate(process.argv);
|
||
|
for (var i = 0; i < binding.length; i++) {
|
||
|
console.log('parent',
|
||
|
'binding.set(' + i + ', ' + i + ')',
|
||
|
binding.set(i, i));
|
||
|
}
|
||
|
} else {
|
||
|
for (var i = 0; i < binding.length; i++) {
|
||
|
console.log('child', 'binding.get(' + i + ')', binding.get(i));
|
||
|
}
|
||
|
}
|
||
|
|