1 2 3 4 5 6 7 8 9 10 11 12 13 14 | function main() { var inputObject = { input: ["one", "two", "three", "fifteen", "one hundred"], counter:0, }; for(; inputObject.counter< inputObject.input.length; inputObject.counter++) { if (inputObject.input[inputObject.counter].length > 8) { throw "Input String Too Big"; } } } main(); |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 | $ cd node-v0.12.4-linux-x64/bin/ $ ulimit -c unlimited $ ./node --abort-on-uncaught-exception ../../test.js Uncaught Input String Too Big FROM main (/home/sian/test.js:11:7) Object.<anonymous> (/home/sian/test.js:16:1) Module._compile (module.js:460:26) Object.Module._extensions..js (module.js:478:10) Module.load (module.js:355:32) Function.Module._load (module.js:310:12) Function.Module.runMain (module.js:501:10) startup (node.js:129:16) node.js:814:3 Illegal instruction (core dumped) |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 | !nodeoverview { Node Property Value ---------------------- ------------------------------------------------------------- Node version 0.12.4 Path to executable /home/sian/node-v0.12.4-linux-x64/bin/node Architecture x64 Platform linux Command Line Arguments /home/sian/node-v0.12.4-linux-x64/bin/node /home/sian/test.js Execution Arguments --abort-on-uncaught-exception Process ID 5643 Dependency Version ----------- ---------- http_parser 2.3 node 0.12.4 v8 3.28.71.19 2.2 [...] |
1 2 3 4 5 6 | !threads { Thread ID: 0x74c9 (29897) IP: 0x0000000000eb112d !stack 29897 } |
欢迎光临 电子技术论坛_中国专业的电子工程师学习交流社区-中电网技术论坛 (http://bbs.eccn.com/) | Powered by Discuz! 7.0.0 |