while后不加大括号,甚至加了一个分号,这种写法是什么意思?为什么不会报错呢?
源码:
function start() { console.log("Request handler 'start' was called."); function sleep(seconds) { var startTime=new Date().getTime(); while(new Date().getTime()<startTime+seconds);//这句 } sleep(10000); return 'hello Start'; }function upload() { console.log("Request handler 'upload' was called."); return 'Hello Upload'; } exports.start = start; exports.upload = upload;
ABOUTYOU
相关分类