Search code examples
xcodemacoscocoabetavisual-glitch

Xcode Version 6.1 (6A1046a) Glitch: Xcode does not recognize any variables or objects


I am using Xcode Version 6.1 (6A1046a) to write Cocoa applications in Swift, and lately when I work on a certain project Xcode doesn't recognize any Cocoa objects or any variables I have created. Every line comes up with an error saying something like "'DvorakController' does not have a member named 'forwardButton'" (forwardButton is a variable I have created). Or, IBOutlets that I previously created throw errors like "Use of undeclared type 'NSButton'" when I have the import Cocoa tag at the top. The weird thing is that as soon as I run the application all the errors go away, and everything runs smoothly. However, the Xcode suggestion filler-in thing does not work which is very frustration.

As far as I can tell I haven't done anything that would cause this; I'm writing a pretty benign app. I assume this is because I'm using a beta version of Xcode. Is there anything I can do to get rid of this problem, or any list of beta Xcode problems I can search? (Quitting Xcode, restarting my computer, etc. does not work)

Thanks in advance,
bigelerow


Solution

  • When restarting Xcode doesn't fix this sort of strange behavior, you can try removing the contents of the derived data folder. See Can I safely delete contents of Xcode Derived data folder?.