Input-mask-ios: XCode 10 and Swift 4.2 fails to build

Created on 21 Sep 2018  ·  4Comments  ·  Source: RedMadRobot/input-mask-ios

The pod does not compile with Xcode 10 and Swift 4.2

Installation Type

  • Cocoapods

Additional context

/Users/Damasceno/Documents/GitHub/caronae-ios/Pods/InputMask/Source/InputMask/InputMask/Classes/View/MaskedTextFieldDelegate.swift:167:72: error: 'UITextFieldDidEndEditingReason' has been renamed to 'UITextField.DidEndEditingReason'
    open func textFieldDidEndEditing(_ textField: UITextField, reason: UITextFieldDidEndEditingReason) {
                                                                       ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
                                                                       UITextField.DidEndEditingReason
UIKit.UITextFieldDidEndEditingReason:3:18: note: 'UITextFieldDidEndEditingReason' was obsoleted in Swift 4.2
public typealias UITextFieldDidEndEditingReason = UITextField.DidEndEditingReason
bug

Most helpful comment

I'm going to issue an update today or tomorrow.
Please, stay tuned.

All 4 comments

As a temporary workaround, open Pods project settings, select InputMask target, and change swift language version to Swift 4. Note that you need to do this every time you run pod install.

It would be interesting to see the PR merged since currently most libs are already updating their version for swift 4.2.

I'm going to issue an update today or tomorrow.
Please, stay tuned.

Fixed in 4.0.1.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

caioremedio picture caioremedio  ·  6Comments

osterlind picture osterlind  ·  3Comments

beltik picture beltik  ·  6Comments

Robuske picture Robuske  ·  4Comments

LinusGeffarth picture LinusGeffarth  ·  4Comments