In my build setup, some executable C code is in files #included within other source files. When debugging the included code, Step works ok but Step Over keeps going until the next line of the file it was included from. Regardless of the included filename extension (.h, .c, or other). Is there a way to get Step Over to stay in the include-file code? As a workaround, stepping in assembly mode works but is tedious.
The uVision Debugger "Single-Stepping" features are explained at:
https://www.keil.com/products/uvision/db_exe_step.asp
An idea might be, that you have the chance to additionally open relevant files during a Debugging session:
https://www.keil.com/support/man/docs/uv4/uv4_db_opennofile.htm
Jack Morrison said:In my build setup, some executable C code is in files #included within other source files.
The brutally simple answer would be: don't do that.
Thanks. I know how "Step Over" is supposed to work. But it doesn't run a single line. GDB certainly knows how to do this, and "Step" works fine when it's ok to go into a function call.
The "open files" option seems to no effect on this behavior.
Yeah, that's a workaround. But not too helpful. I didn't want to clutter up the question explaining why it's useful to do that. A very common example is an inline class method. Another is a unit test wrapper that includes the code under test, without having to use special definitions for "static" and "private".