0

I have just updated my Mac and Xcode.

Mac: 10.10.3 (14D131)

Xcode: 6.3 (6D570)

Yesterday, I have built my app, and tested it on simulator and real iPhone device.

However, after the updates, now I am not able to build with the following errors:

1- Cannot load module 'UIKit' as "UiKit"

I used to use this import statment: import UiKit I have never used import UIKit with uppercase UI instead of the Ui

I have done a "find and replace" operation to replace 39 occurrences. Then I got the following errors on built:

2- 'Initializer does not override a designated initializer from its superclass'. I have removed

3- Now I got many errors requiring me to change as to as!

I am getting lots of errors!! I have checked out a commit known to be working, but no use!

Is it related to the update? Am I missing something with this update? enter image description here Fullscreen image

Edit 2: After converting to Latest Swift Syntax and Cleaning everything. I got the following errors (But it is strange if I solved one error the all list changes):

New Errors

malhobayyeb
  • 2,725
  • 11
  • 57
  • 91

4 Answers4

4

Try first to convert your project to "Lastest swift syntax", then clean your project (and eventually Derived data)

enter image description here

Duyen-Hoa
  • 15,384
  • 5
  • 35
  • 44
  • I have switched to latest swift syntax. Cleaned and removed derived data. But still I have same issues. Any way to revert xcode back? :( – malhobayyeb Apr 13 '15 at 10:30
  • Can you show us the new errors? Btw, it must be UIKit but not UiKit – Duyen-Hoa Apr 13 '15 at 10:33
  • 1
    It seem that there some classes that have not been converted correctly to Swift 1.2. You have to add your self some ! for 'as' keyword. For error which has white point inside red circle, just click to that icon then choose to apply auto-correct. For Set problem, if you want to get all items, convert to array. For initialize problem, take a look at: http://stackoverflow.com/questions/29068534/build-error-when-trying-to-override-an-initializer-in-xcode-6-3-beta-3 – Duyen-Hoa Apr 13 '15 at 11:36
1

You must change everything to Swift 1.2 because the latest XCODE version don't support swift 1.1 Here is a great Link about Swift 1.2

BilalReffas
  • 8,132
  • 4
  • 50
  • 71
0

Try by cleaning the project and deleting the derived data.

Manish Agrawal
  • 10,958
  • 6
  • 44
  • 76
-1

It was caused by simple typo. It should be UIKit - not UiKit or UIkit or any other spelling. I solved my code with this simple change. Hope that help.