Community
Participate
Working Groups
When pressing step-return from a method that returns a value, CDT shows that value in the Variables view. If the step-return ends up on a line that has a breakpoint, that value is not shown. The reason is that MIStack expects a *stopped event from GDB with reason "function-finished" which translates to MIFunctionFinishedEvent.java, however, when the operation lands on a line with a breakpoint, GDB sends a *stopped event with reason "breakpoint-hit" which is a different type of event.
New Gerrit change created: https://git.eclipse.org/r/48796
> New Gerrit change created: https://git.eclipse.org/r/48796 Since the return value of a method can be part of different *stopped events such as: *stopped,reason="breakpoint-hit" *stopped,reason="function-finished" I pushed the logic of handling the return value in the base class MIStoppedEvent. I only modified MIBreakpointHitEvent.java and MIFunctionFinishedEvent.java to use that logic, but if yet another type of stopped event needs it, we can now easily support it. I didn't make all the changes now because it adds new API and deprecates others, which I didn't want to do unless necessary.