[Solved] VisualStudio 2013 with Qt5.5 addin debugging woes
-
Hi,
I installed the Qt5.5 environment along with the addin for MSVC 2013. In general it works really great, but one thing is driving me mad; debugging!
Most of the time, variables in the debugging view are invalid, and also the program pointer jumps around when debugging. The only way I can get reasonable data out, is by using qDebug() - automatic or local variables make no sense, which is a major annoyance.I have not tried to make a very simple qt application, to verify if it is a general problem or if it has anything to do with the settings of my current project.
Any tips anyone?
-
the program pointer jumps around when debugging
It doesn't sound like a Qt problem. This happens when you're debugging an optimized build.
Are you debugging a Release or Debug build? If it's Debug then check the project setting under Configuration Properties -> C/C++ -> Optimization and see if Optimization option is set to anything other than Disabled (which is what it should be for debug build). -
Thanks, I think that solved my problem. The wrong optimization setting must have come while setting up the project. Disabling the optimization makes the debugging work again. Thanks!
As as side question, you may be able to tell me why edit-and-continue doesn't work for my project? When I edit a line, it just says the executable does not anymore match the code.
-
Make sure the right options are set as described here and that you're not in one of the unsupported scenarios. Also note that edit and continue is not supported in VS2013 for native projects when compiling for x64 (that support is back in VS2015).