Top "Swift4.2" questions

Use this tag only for questions directly related to changes in version 4.2 of Apple's Swift programming language.

'Build input file cannot be found' Swift 4.2, Xcode 10.0

I am getting the following error when building in Xcode 10.0 with swift 4.2:

xcode10 swift4.2 xcode11
Type 'NSNotification.Name' has no member 'keyboardDidShowNotification'

I'm getting this error with Swift 4.2 Type 'NSNotification.Name' has no member 'keyboardDidShowNotification' Here is my code: NotificationCenter.default.addObserver(…

ios keyboard-events nsnotificationcenter swift4.2
DispatchQueue : Cannot be called with asCopy = NO on non-main thread

I am presenting the UIAlertController on the main thread as : class HelperMethodClass: NSObject { class func showAlertMessage(message:String, viewController: UIViewController) { …

swift grand-central-dispatch swift4.2 dispatch-queue
UIEdgeInsetsInsetRect' has been replaced by instance method 'CGRect.inset(by:)

I made the mistake up updating my project to Swift 4.2 without waiting for pods to be updated. I have slowly …

ios swift xcode swift4.2
Swift 4.2 imagePickerController issue

Trying to pass chat client from swift 4 to swift 4.2 and with picker i found trouble. UIImagePickerControllerEditedImage Cannot subscript a value …

swift uiimagepickercontroller swift4.2
Upload files with parameters from multipartformdata using alamofire 5 in ios swift

I am trying upload files with parameters (multipartformdata) but i can't do it with new version Alamofire 5, if you have …

ios swift alamofire multipartform-data swift4.2
Could not load IOSurface for time string. Rendering locally instead swift 4

Could you help me with this problem when I running my project : Could not load IOSurface for time string. Rendering …

ios swift3 swift4.2
Error with notification names while converting code to Swift 4.2

The code below was working fine before Swift 4.2: NotificationCenter.default.addObserver(self, selector: #selector(keyboardWillChange(notification:)), name: NSNotification.Name.UIKeyboardWillShow, …

nsnotifications xcode10 swift4.2
Type 'NSNotification.Name' has no member 'UITextField'

With Swift 4.2, getting following error, that was working fine with Swift 4. Type 'NSNotification.Name' has no member 'UITextField' Here is …

ios nsnotificationcenter swift4.2
Xcode 10 convert to Swift 4.2 fails

I am getting this error trying to migrate to Swift 4.2 using the Xcode provided conversion tool. How do I fix …

ios swift xcode xcode10 swift4.2