Following are warnings and errors will come while upgrading from Swift 4.x to Swift 4.2 in Xcode 10.0
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 |
'UITableViewCellEditingStyle' has been renamed to 'UITableViewCell.EditingStyle' 'UITableViewAutomaticDimension' has been renamed to 'UITableView.automaticDimension' 'NSAttributedStringKey' has been renamed to 'NSAttributedString.Key' 'UITextFieldViewMode' has been renamed to 'UITextField.ViewMode' 'UIApplicationOpenSettingsURLString' has been renamed to 'UIApplication.openSettingsURLString' 'UIControlState' has been renamed to 'UIControl.State' 'UIAlertControllerStyle' has been renamed to 'UIAlertController.Style' 'UITableViewCellSelectionStyle' has been renamed to 'UITableViewCell.SelectionStyle' 'UITableViewCellSelectionStyle' has been renamed to 'UITableViewCell.SelectionStyle' 'bringSubview(toFront:)' has been renamed to 'bringSubviewToFront(_:)' 'UITableViewAutomaticDimension' has been renamed to 'UITableView.automaticDimension' 'UIImageOrientation' has been renamed to 'UIImage.Orientation' 'UIBlurEffectStyle' has been renamed to 'UIBlurEffect.Style' 'UIViewContentMode' has been renamed to 'UIView.ContentMode' 'UIApplicationLaunchOptionsKey' has been renamed to 'UIApplication.LaunchOptionsKey' 'UISwipeGestureRecognizerDirection' has been renamed to 'UISwipeGestureRecognizer.Direction' 'UIImageJPEGRepresentation' has been replaced by instance method 'UIImage.jpegData(compressionQuality:)' 'childViewControllers' has been renamed to 'children' 'UIEdgeInsetsMake' has been replaced by 'UIEdgeInsets.init(top:left:bottom:right:)' 'UIAlertControllerStyle' has been renamed to 'UIAlertController.Style' 'willMove(toParentViewController:)' has been renamed to 'willMove(toParent:)' 'removeFromParentViewController()' has been renamed to 'removeFromParent()' 'addChildViewController' has been renamed to 'addChild(_:)' 'didMove(toParentViewController:)' has been renamed to 'didMove(toParent:)' 'UIImagePickerControllerSourceType' has been renamed to 'UIImagePickerController.SourceType' 'UIImagePNGRepresentation' has been replaced by instance method 'UIImage.pngData()' 'UIApplicationDidEnterBackground' has been renamed to 'UIApplication.didEnterBackgroundNotification' 'UIApplicationDidBecomeActive' has been renamed to 'UIApplication.didBecomeActiveNotification' 'AVAudioSessionCategoryAmbient' has been renamed to 'AVAudioSession.Category.ambient' 'addChildViewController' has been renamed to 'addChild(_:)' 'setCategory' is unavailable in Swift 'kCAMediaTimingFunctionLinear' has been renamed to 'CAMediaTimingFunctionName.linear' 'NSLayoutFormatOptions' has been renamed to 'NSLayoutConstraint.FormatOptions' 'UIViewAnimationOptions' has been renamed to 'UIView.AnimationOptions' 'bringSubview(toFront:)' has been renamed to 'bringSubviewToFront(_:)' 'UIInterfaceOrientationIsPortrait' has been replaced by property 'UIInterfaceOrientation.isPortrait' 'UIInterfaceOrientationIsPortrait' has been replaced by property 'UIInterfaceOrientation.isPortrait' 'UIApplicationUserDidTakeScreenshot' has been renamed to 'UIApplication.userDidTakeScreenshotNotification' 'UIWebViewNavigationType' has been renamed to 'UIWebView.NavigationType' 'UIKeyboardWillShow' has been renamed to 'UIResponder.keyboardWillShowNotification' Missing argument label 'preferredTimescale:' in call Static declarations are implicitly 'final'; use 'public' instead of 'open' |
Upgrade your project to Swift 4.2 in Xcode 10.
Happy Coding ?
If you have any questions, comments, suggestions or feedback then contact me on Twitter @ashishkakkad8. I am retweeting many tips on my wall of twitter you can follow me for updates of iOS.