Search code examples
xcodedebuggingglobal-variables

Does Xcode have a watch window?


Does Xcode have a watch window for variables? It has a window for local variables but that's not much help when I want to watch the value of a global.

I've been spoiled by VisualStudio, I know.


Solution

  • Solved! Right-clicking in the local variables window brings a menu option of "Add Expression". Type your variable name and now you are watching your variable/expression.

    The language of "expression" instead of the more familiar "variable" threw me quite a bit. Hard to search for a solution when I have the terminology wrong. Seems obvious now.