Xcode debugger does not display the value of my variables.
Q: The debugger doesn't show my variables' value. How can I view them?
A: The debugger may not show the value of your variables for any of the following reasons:
The Optimization level is not set to None for the Debug configuration.
Be sure to set it to
Nonefor Objective-C apps as shown in Figure 1 and for Swift apps as shown in Figure 2.
The Build Configuration pop-up menu is set to Release in the scheme editor's Run action settings pane.
In Xcode, open the scheme editor by choosing Product > Scheme > Edit Scheme…, select the Run action for your app in the scheme actions pane, then set Build Configuration to
Debugas seen in Figure 3.
Document Revision History
New document that describes causes that can prevent the debugger from showing the value of your variables.