swiftxcodeswift3compiler-errorsxcode8

Xcode not displaying compile errors


I'm working in a specific Xcode project and deliberatly making errors in my code (like using undeclared variables), but Xcode doesnt seem to show any compile errors in my code.


Solution

  • Besides the DerivedData folder, also try cleaning Xcode caches completely:

    rm -rf $HOME/Library/Caches/com.apple.dt.Xcode/
    

    I would recommend also killing the SourceKit process — always a source of issues these days! — but since you are already did a full reboot, so looks like you are good there.

    If everything fails, you might consider upgrading to the latest Xcode, version 8.3. Just be aware that:

    Xcode 8.3 no longer supports Swift 2.3. Please migrate your projects containing Swift 2.3 code to Swift 3 syntax by opening the project and choosing Edit > Convert > To Current Swift Syntax.