函数体中return下面的代码不执行,但是需要预解析

//函数体中return下面的代码不执行,但是需要预解析
function fn(){
console.log(num);//undefined
return function(){

};
var num=100;
}
fn();

原文地址:https://www.cnblogs.com/qiqi105/p/8250289.html