Reputation: 1363
Today I updated my project to Swift 3.0
.
The project worked smoothly with Xcode 7.3
and the autocomplete
had no problems. After updating to Swift 3
the autocomplete in Xcode almost disappeared (needs 1 minute).
Autocomplete works great with new projects, only this one has the problem.
I tried general performance solutions like removing "+"
on Strings
and setting arrays without appending, but with no luck.
I tried deleting Derived Data
, Clean project
I have everything from the components and simulator sections
My project uses several Pods
EDIT:
When I remove suggest while typing and force it with control and space, then it works most of the times. But its not working while I type (error correction too).
When I do Pod install, although every Pod is in Swift 3 now, it asks me to convert again the project. I click "OK" and it shows 999+ errors but while generating convertion it sais there is not any convertion needed and "Update" (errors are gone when I clean the project).
Thank you
Upvotes: 12
Views: 1958
Reputation: 950
Yes i am also getting problem with converting my old swift 2.3 project to swift 3. And I have return back to swift 2.3 because there are lots of library which are still using swift 2.3 and the xcode is try to convert the whole library code and i also got too much error. So i recommended you to use swift 2.3 in your existing app. You can try swift 3 for new apps.
Upvotes: 0
Reputation: 35402
I had the same problem with autocompletion during my project conversion from swift 2.x to swift 3: autocompletion looked partially disappeared so I follow these steps and from that moment everything around autocompletion works fine (I hope it continue..):
From terminal launch this command:
rm -rf ~/Library/Developer/Xcode/DerivedData/*
Close Xcode. Now you could try to stop indexing and re-start it because it's linked to autocompletion: if you leave it disabled, autocompletion stop to work. So from terminal do:
defaults write com.apple.dt.XCode IDEIndexDisable 1
Launch Xcode and if you want you can check if your autocompletion is now disabled, so re-close Xcode and type :
defaults delete com.apple.dt.Xcode IDEIndexDisable
This key remove the previous and correct index settings to default (enable), so you can try to re-open Xcode and check if autocompletion works.
My explanation for what happened to my project is that probably I've stopped accidentally indexing process (I'm impatient), so autocompletion has suffered in fact it worked partially. With this "forced re-indexing" I've solved.
Hope it can help you.
Upvotes: 3