Jump to content
  • Advertisement
Sign in to follow this  
zedz

MSVC debugging no STL

This topic is 3287 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

How can I disable stepping through the STL files(*) when Im debugging a program. eg */ breakpoint */ F11 (step into) + it enters some STL file eg vector(.h), repeat this step a few times until finally Im in my code that I want to look at The reason being is 99.9% of the time the STL file has no relevant info thus Im wasting time cheers zed (*) or something else, i.e. can I mark some files with a flag saying, ignore these.

Share this post


Link to post
Share on other sites
Advertisement
I don't think you can. But if you don't want that behaviour, you shouldn't be using "step into". "Step over" will execute the code line by line and won't drill into functions, and "step out" will execute until the call stack is popped.

Share this post


Link to post
Share on other sites
Yeah, I usually use F10 (step over) unless I explicitly want to step in (F11). If I accidentally step into a function I didn't mean to, Shift-F11 (step out) will continue execution until the current function ends.

Share this post


Link to post
Share on other sites
I'm fairly certain that zedz is referring to cases like this:

std::vector<int> v;
// stuff
someFunc(v[0], v[1], v[2], v[3]);

Where hitting F11 on someFunc will indeed first step into operator[] four times. The fastest way around this is to put a breakpoint on the first line inside the function you're interested in and do F10, so it steps over all the vector code and breaks inside your function, but I agree it can be rather annoying sometimes, especially if your code is SC++L-heavy.

I vaguely remember there being a file somewhere that let you edit the debugging behavior of certain types and how they're displayed in the watch window, but it's been forever since I've messed with that and my Google-foo is weak this late in the evening.

Share this post


Link to post
Share on other sites
Zipster yes thats the case Im talking about
Yes I could put a breakpoint at the place I want to look at, but the thing is often I dont know exactly what I want to look at, one thing I certainly dont want to look at is STL header files :)

Im pretty sure this would be able to be done as its a commonsense improvement, the problem is as Ive found some of msvc features are undocumented for some reason

cheers anyways

Share this post


Link to post
Share on other sites
which version? in 2005+ there's an option called "Just my code"
Quote:

To enable or disable Just My Code debugging
On the Tools menu, choose Options.

In the Options dialog box, open the Debugging node and then choose General.

Select or clear Enable Just My Code.




Share this post


Link to post
Share on other sites
Quote:
Original post by ChaosEngine
which version? in 2005+ there's an option called "Just my code"
That's managed code only, it doesn't work for (native) C++.

Share this post


Link to post
Share on other sites
There are lots of neat little (undocumented) things you can do with Visual Studio's autoexp.dat file. One of these is NoStepInto, as explained here.

Edit: Looks like that was a VS6.0 only trick, it's now been moved to the registry.

Share this post


Link to post
Share on other sites
Quote:
Original post by Codeka
Quote:
Original post by ChaosEngine
which version? in 2005+ there's an option called "Just my code"
That's managed code only, it doesn't work for (native) C++.


D'oh! you're right. For some reason, I was sure it worked for native C++.

Driv3MeFars solution should work though.

Share this post


Link to post
Share on other sites
thanks Driv3MeFar that worked a treat, I wish Ild known of it earlier

heres what u need

HKEY_CURRENT_USER\Software\Microsoft\ ( VCExpress\8.0 ) \NativeDE\StepOver
10 ................ stl\\:\\:.*=nostepinto

obviously u need to change whats in the ( ) depending on your VC version

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!