I'm working on an iPhone game and have now a big problem.
The project is getting larger and larger. Now Xcode takes forever for indexing, typing is laggy, autocomplete takes some seconds, building the file takes forever and so on.
Im using Xcode 8 Beta 6, but that is not the problem. If i open another project which is not so big the performance is normal.
I deleted the files under DerivedData but that did not help.
My question is: In this big project I have one GameScene.swift file with 7500 lines of code. Is that causing the problem? Or should Xcode be able to perform this much code in one file and the problem is more the code itself? Ive read that for example the syntax of an array can cause the problem, or if you declare an array with 30 or more objects (both not the case for me).
I think it's something inside the code which causes the problem and not the size of the code - but I don't know how to find it out.
Edit: Oh, the process SourceKitService has almost always 100% CPU use.