as in the title is there a way in Xcode to Add Watch or Inspect a code segment in Xcode
for example how can I see the result of [myObject aMethod] with actually stepping
In the debugger console, if you stop at a breakpoint you can type po [myObject aMethod]
to see the return value (if it's not an id
type return value, use p ([return type here])[myObject aMethod]
).
You can also set a breakpoint action to print something out without pausing, just right click to edit the breakpoint:
To actually see the value change while you step through, you can right click the watch list of the debug area and choose "Add Expression..."