In Xcode when compiling my project after adding a file "CDExceptions.swift", I am getting this error. The file contents appear to be making a component "SWBBuildService" in Xcode crash.
When I press the "Reopen" it seems to compound the error with:
Now here is where it gets wiggy... when I remove the file from the project, the project compiles fine without Xcode tooling crashes. Add the file back in and Xcode tooling crashes happen.
I copy all the text contents of the file into a new file and add that file to the project. (different file, different name, different location) Same issue. Suggests contents of file. Swift flags nothing in the contents as a problem or warning
Now here is where it gets really strange, I copy all the functions out of "CDExceptions.swift" into one of the regular project files, remove "CDExceptions.swift" from the project, and the compile goes through cleanly as well; no Xcode tool crash, no compile errors. Be aware that "CDExceptions.swift" only contains utility functions... no classes no structs, just a bunch of functions.
And before the questions are asked:
- Cleaned the build folder, deleted the thing at one point, no help
- Remove "CDExceptions.swift" and project builds fine and fails to build immediately upon adding the file "CDExceptions.swift" back in
- Functions from "CDExceptions.swift", when added to the bottom of any pre-existing project file compile fine as long as the "CD Exceptions.swift" file is not in the project. Using the functions that were extracted from "CDExceptions.swift" work as expected
- Renaming file does not help
- Recreating file does not help
- Moving file from one directory to another does not help
- Moving file in the project listing in Xcode, does not help
- Only native code is being used in the project, nothing foreign, no cocopods, no react
- reloaded Xcode from the App Store, does not help
Any ideas about what might be causing this anyone?
