Time is tighter, just remember! Jot down small successes with small failures and keep moving forward.
Story
More than a day more time, (in fact, in the last few days vaguely appeared this BUG, only then did not systematically or frequently debug run and so did not find) was a BUG tortured!
Now, in summary, the root cause is not skilled in development tools. This BUGappears again today because the code is too long and there is no way to analyze the diagnosis roughly based on the code execution process and its own experience.
Today's rest room (temporarily tortured by bugs, have to rest!) ), I suddenly remembered that there had been several observations of the call stack before. So, seize the time to try it, sure enough success--a very big BUG was dug out!
Summarize
The main reasons for this error are: The code is very long (nearly 5000 lines), and repeatedly modified, sometimes a lot of content inadvertently modified incomplete (this is a typical unintentional, and many people will appear errors), resulting in a lot of wasted time.
One of the conclusions is this: use of the system-provided "refactoring" functionality later on (The VS2012 integrated development Environment I use today supports personal feeling that is already very good), even for longer sub-functions as much as possible, so as to minimize the above problem! (Sometimes, the individual is a bit proud, in the longer function inside the modification will not use "refactoring"!) This is the cause of the above bug. )
The second conclusion is: When the system is running wrong , use the call stack a lot. Today's call stacks can help you get closer to the source of the bug lately, VERY good! Look at this one of mine.
650) this.width=650; "src=" http://s3.51cto.com/wyfs02/M00/48/6C/wKioL1QH5UvTGqyHAAEqzDQm034210.jpg "title=" capture. JPG "alt=" Wkiol1qh5uvtgqyhaaeqzdqm034210.jpg "/>
Just double-click the line in the appropriate call stack, the source immediately appears in front of it. Almost the first time to help you catch the BUG !
This article is from the "Green Peak" blog, please make sure to keep this source http://zhuxianzhong.blog.51cto.com/157061/1548665
Debug VC + + code with call stack more