Causing VS2010 debugger to break when Debug.Assert fails

后端 未结 7 2078
南笙
南笙 2020-12-15 09:15

Is there any way to cause Visual Studio 2010 to break while debugging when the argument of Debug.Assert evaluates to false?

Example: in my

相关标签:
7条回答
  • 2020-12-15 09:51

    If by debugging you mean using "Step Into" feature, see this MS's answer to the problem.

    http://connect.microsoft.com/VisualStudio/feedback/details/522995/system-diagnostics-debug-assert-doesnt-pop-up-messagebox-correctly-when-step-into-it-in-vs-2010-and-2008

    Using "Step Over" at the Assert statement does solve the issue too (for me).

    0 讨论(0)
提交回复
热议问题