AfxDebugBreak (Debugging)
This topic applies to:
Edition |
Visual Basic |
C# |
F# |
C++ |
Web Developer |
---|---|---|---|---|---|
Express |
Native only |
||||
Pro, Premium, and Ultimate |
Native only |
MFC provides a special AfxDebugBreak function for hard-coding breakpoints in source code:
AfxDebugBreak( );
On Intel platforms, AfxDebugBreak produces the following code, which breaks in source code rather than kernel code:
_asm int 3
On other platforms, AfxDebugBreak merely calls DebugBreak.
Be sure to remove AfxDebugBreak statements when you create a release build or use #ifdef _DEBUG to surround them.