"Steplast is not meaningful for the current line."
For example,
(gdb) 4 int k = 10; (gdb) sl
To execute the steplast command in C++ compiled applications, you must compile the application using the HP aC++ version A.03.50 or later with the
In C++, the steplast command is helpful while debugging heavy templated functions, because it directly steps into the call, thus skipping the constructor calls, if any. This behavior is unlike the step command that steps into the constructor itself.
Consider the following example:
void call_me ( string s ) ... (gdb) 10
call_me ( "hello" );
(gdb) steplast call_me (s=static npos = 4294967295,
static nullref = ref_hdr = mutex_= dummy1 = 0x7f4f79e0, dummy2 = 2136325568, refs_ = 2136327612,
capacity_ = 2136327468, nchars_ = 2136327464, eos_char = 64 '@', alloc_ = <No data fields>,
value_allocator = alloc_ = 0x7f7f133c, data_ = 0x40003a64 "hello") at str.C:55 printf ("Will just print the value of \n");
If there are multiple
foo(bar()) + bar(foo());
Debug foo(), use the finish command to exit from the first
(gdb)10 foo( bar() ) + bar( foo() ) (gdb) sl Use the steplast (sl) command to step
14.28 Getting information from a non-debug executable
You can get some information about the arguments passed to the functions displayed in the stack trace in a
When GDB has no debug information; it does not know where the arguments are located or even the type of the arguments. GDB cannot infer this in an optimized,
However, for integer arguments you can nd the first few parameters for the
226