码迷,mamicode.com
首页 > 其他好文 > 详细

禁止vs2015 debug时跳转到STL中 Not step into

时间:2015-06-17 17:56:17      阅读:657      评论:0      收藏:0      [点我收藏+]

标签:

打开下面这个文件。注意这个文件是只读文件,需要先去掉只读属性才能修改
  1. C:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\Packages\Debugger\Visualizers\default.natstepfilter

</StepFilter>之前插入一行
<Function><Name>std::.*</Name><Action>NoStepInto</Action></Function>

也就是将
  1. <?xml version="1.0" encoding="utf-8"?> <StepFilter xmlns="http://schemas.microsoft.com/vstudio/debugger/natstepfilter/2010"> <Function><Name>__security_check_cookie</Name><Action>NoStepInto</Action></Function> <Function><Name>__abi_winrt_.*</Name><Action>NoStepInto</Action></Function> <Function><Name>_ObjectStublessClient.*</Name><Action>NoStepInto</Action></Function> <Function><Name>_Invoke@12</Name><Action>NoStepInto</Action></Function> <Function><Name>_RTC_Check(Esp|StackVars)</Name><Action>NoStepInto</Action></Function> <Function><Name>_chkstk</Name><Action>NoStepInto</Action></Function> <Function><Name>ATL::CComPtrBase.*::operator&amp;</Name><Action>NoStepInto</Action></Function> <Function><Name>ATL::CComPtrBase.*::operator-&gt;</Name><Action>NoStepInto</Action></Function> <Function><Name>ATL::CHeapPtrBase.*::operator&amp;</Name><Action>NoStepInto</Action></Function> <Function><Name>ATL::CHeapPtrBase.*::operator-&gt;</Name><Action>NoStepInto</Action></Function> <Function><Name>ATL::CComBSTR::operator&amp;</Name><Action>NoStepInto</Action></Function> <Function><Name>std::forward&lt;.*</Name><Action>NoStepInto</Action></Function> <Function><Name>std::move&lt;.*</Name><Action>NoStepInto</Action></Function> <Function><Name>Platform::EventSource::Invoke.*</Name><Action>NoStepInto</Action></Function> <Function><Name>IID_PPV_ARGS_Helper&lt;.*</Name><Action>NoStepInto</Action></Function> <Function><Name>Microsoft::WRL::ComPtr&lt;.*&gt;::operator&amp;</Name><Action>NoStepInto</Action></Function> <Function><Name>Microsoft::WRL::ComPtr&lt;.*&gt;::operator-&gt;</Name><Action>NoStepInto</Action></Function> <Function><Name>Microsoft::WRL::Details::ComPtrRef.*</Name><Action>NoStepInto</Action></Function> <Function><Name>operator new</Name><Action>NoStepInto</Action></Function> </StepFilter>
修改为
  1. <?xml version="1.0" encoding="utf-8"?>
  2. <StepFilter xmlns="http://schemas.microsoft.com/vstudio/debugger/natstepfilter/2010">
  3. <Function><Name>__security_check_cookie</Name><Action>NoStepInto</Action></Function>
  4. <Function><Name>__abi_winrt_.*</Name><Action>NoStepInto</Action></Function>
  5. <Function><Name>_ObjectStublessClient.*</Name><Action>NoStepInto</Action></Function>
  6. <Function><Name>_Invoke@12</Name><Action>NoStepInto</Action></Function>
  7. <Function><Name>_RTC_Check(Esp|StackVars)</Name><Action>NoStepInto</Action></Function>
  8. <Function><Name>_chkstk</Name><Action>NoStepInto</Action></Function>
  9. <Function><Name>ATL::CComPtrBase.*::operator&amp;</Name><Action>NoStepInto</Action></Function>
  10. <Function><Name>ATL::CComPtrBase.*::operator-&gt;</Name><Action>NoStepInto</Action></Function>
  11. <Function><Name>ATL::CHeapPtrBase.*::operator&amp;</Name><Action>NoStepInto</Action></Function>
  12. <Function><Name>ATL::CHeapPtrBase.*::operator-&gt;</Name><Action>NoStepInto</Action></Function>
  13. <Function><Name>ATL::CComBSTR::operator&amp;</Name><Action>NoStepInto</Action></Function>
  14. <Function><Name>std::forward&lt;.*</Name><Action>NoStepInto</Action></Function>
  15. <Function><Name>std::move&lt;.*</Name><Action>NoStepInto</Action></Function>
  16. <Function><Name>Platform::EventSource::Invoke.*</Name><Action>NoStepInto</Action></Function>
  17. <Function><Name>IID_PPV_ARGS_Helper&lt;.*</Name><Action>NoStepInto</Action></Function>
  18. <Function><Name>Microsoft::WRL::ComPtr&lt;.*&gt;::operator&amp;</Name><Action>NoStepInto</Action></Function>
  19. <Function><Name>Microsoft::WRL::ComPtr&lt;.*&gt;::operator-&gt;</Name><Action>NoStepInto</Action></Function>
  20. <Function><Name>Microsoft::WRL::Details::ComPtrRef.*</Name><Action>NoStepInto</Action></Function>
  21. <Function><Name>operator new</Name><Action>NoStepInto</Action></Function>
  22. <Function><Name>std::.*</Name><Action>NoStepInto</Action></Function>
  23. </StepFilter>


经过测试,这个方法也适用于VS2013,当然default.natstepfilter的文件路径要修改一下
如果需要详细定制StepInto,请查看参考资料





禁止vs2015 debug时跳转到STL中 Not step into

标签:

原文地址:http://www.cnblogs.com/cmicat/p/4583942.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!