调试 debug版本的内联函数时,会发现内联函数并没有被展开,需要设置C/C++->Optimization->Inline Function Expansion 为 “Only __inline (/Ob1)”。
再编译,会有一个错误,“cl : Command line error D8016 : '/Ob1' and '/ZI' command-line options are incompatible”。
设置C/C++->General->Debug Information Format 为 “Program Database (/Zi)” 即可。