function getValue() { return [1, 2]; } var [x, y] = getValue();
console.log(x = ${x}, y = ${y});
居然报错了: var [x, y] = getValue(); ^
SyntaxError: Unexpected token [ at exports.runInThisContext (vm.js:53:16) at Module._compile (module.js:374:25) at Object.Module._extensions..js (module.js:405:10) at Module.load (module.js:344:32) at Function.Module._load (module.js:301:12) at Function.Module.runMain (module.js:430:10) at startup (node.js:141:18) at node.js:980:3
使用的node版本是: v5.3.0