RSS .92| RSS 2.0| ATOM 0.3
  • Home
  • About
  •  

    How to avoid unwanted stepping in debugging with visual studio

    April 1st, 2008

    It is always annoying when you are debugging with visual studio, you press F11 on a standard MFC or STL object and the control goes to the constructor or assignment operator of that standard class.

    Eg:

    string myStr = “This is my string”;

    If you press F11 on the above line, it will go to the assignment operator implementation of std::string class.

    To avoid such unwanted stepping into the assignment operator implementation, edit AUTOEXP.DAT , found in the Bin folder of MsDev directory and add the following line.

    [ExecutionControl]

    std::string::operator==NoStepInto

    To avoid stepping into the constructor of string, you can add a line as follows.

    [ExecutionControl]

    std::string::string=NoStepInto

    If you want to disable stepping into all the functions of the class CMyClass,

    [ExecutionControl]

    CMyClass::*=NoStepInto

    If you want to disable stepping into all the functions of classes in the namespace MyNameSpace,

    [ExecutionControl]

    MyNameSpace::*=NoStepInto