Esqarrouth / EZSwiftExtensions

:smirk: How Swift standard types and classes were supposed to work.
MIT License
3k stars 381 forks source link

fix Swift4.0.2 characters warnings #465

Open upoahz opened 6 years ago

upoahz commented 6 years ago

Checklist

EZSwiftExtensionsBot commented 6 years ago
34 Errors
:no_entry_sign: Making non-trivial change requires changelog entry! Please, set trivial change or add entry to changelog.
:no_entry_sign: Sources/ArrayExtensions.swift#L76: value of type ‘Array<Element>’ has no member ‘swapAt’
if i != i+j { self.swapAt(i, i+j) }
:no_entry_sign: Sources/UITextFieldExtensions.swift#L68: ‘count’ is unavailable: there is no universally good answer, see the documentation comment for discussion
return self.text!.count == count
:no_entry_sign: Sources/UITextFieldExtensions.swift#L70: ‘count’ is unavailable: there is no universally good answer, see the documentation comment for discussion
return self.text!.count > count
:no_entry_sign: Sources/UITextFieldExtensions.swift#L72: ‘count’ is unavailable: there is no universally good answer, see the documentation comment for discussion
return self.text!.count >= count
:no_entry_sign: Sources/UITextFieldExtensions.swift#L74: ‘count’ is unavailable: there is no universally good answer, see the documentation comment for discussion
return self.text!.count < count
:no_entry_sign: Sources/UITextFieldExtensions.swift#L76: ‘count’ is unavailable: there is no universally good answer, see the documentation comment for discussion
return self.text!.count <= count
:no_entry_sign: Sources/NSAttributedStringExtensions.swift#L31: use of unresolved identifier ‘NSAttributedStringKey’
copy.addAttributes([NSAttributedStringKey.underlineStyle: NSUnderlineStyle.styleSingle.rawValue], range: range)
:no_entry_sign: Sources/NSAttributedStringExtensions.swift#L65: use of unresolved identifier ‘NSAttributedStringKey’
copy.addAttributes([NSAttributedStringKey.foregroundColor: color], range: range)
:no_entry_sign: Sources/StringExtensions.swift#L57: ‘count’ is unavailable: there is no universally good answer, see the documentation comment for discussion
return self.count
:no_entry_sign: Sources/StringExtensions.swift#L305: ‘count’ is unavailable: there is no universally good answer, see the documentation comment for discussion
detector.enumerateMatches(in: text, options: [], range: NSRange(location: 0, length: text.count), using: {(result: NSTextCheckingResult?, _, _) -> Void in
:no_entry_sign: Sources/StringExtensions.swift#L67: ‘count’ is unavailable: there is no universally good answer, see the documentation comment for discussion
guard count > 0 else { return }
:no_entry_sign: Sources/StringExtensions.swift#L73: ‘count’ is unavailable: there is no universally good answer, see the documentation comment for discussion
guard count > 0 else { return self }
:no_entry_sign: Sources/StringExtensions.swift#L115: ‘count’ is unavailable: there is no universally good answer, see the documentation comment for discussion
guard count > 0 && (0..<length).contains(from) else { return }
:no_entry_sign: Sources/StringExtensions.swift#L123: ‘count’ is unavailable: there is no universally good answer, see the documentation comment for discussion
guard count > 0 && (0..<length).contains(from) else { return self }
:no_entry_sign: Sources/StringExtensions.swift#L132: ‘count’ is unavailable: there is no universally good answer, see the documentation comment for discussion
guard count > 0 else { return }
:no_entry_sign: Sources/StringExtensions.swift#L138: ‘count’ is unavailable: there is no universally good answer, see the documentation comment for discussion
guard count > 0 else { return self }
:no_entry_sign: Sources/StringExtensions.swift#L179: ‘count’ is unavailable: there is no universally good answer, see the documentation comment for discussion
guard count > 0 && (0..<length).contains(from) else { return }
:no_entry_sign: Sources/StringExtensions.swift#L187: ‘count’ is unavailable: there is no universally good answer, see the documentation comment for discussion
guard count > 0 && (0..<length).contains(from) else { return self }
:no_entry_sign: Sources/StringExtensions.swift#L379: use of unresolved identifier ‘NSAttributedStringKey’
let underlineString = NSAttributedString(string: self, attributes: [NSAttributedStringKey.underlineStyle: NSUnderlineStyle.styleSingle.rawValue])
:no_entry_sign: Sources/StringExtensions.swift#L413: use of unresolved identifier ‘NSAttributedStringKey’
let colorString = NSMutableAttributedString(string: self, attributes: [NSAttributedStringKey.foregroundColor: color])
:no_entry_sign: Sources/StringExtensions.swift#L432: use of unresolved identifier ‘NSAttributedStringKey’
attrText.addAttribute(NSAttributedStringKey.foregroundColor, value: color, range: range)
:no_entry_sign: Sources/ArrayExtensions.swift#L76: value of type ‘Array<Element>’ has no member ‘swapAt’
if i != i+j { self.swapAt(i, i+j) }
:no_entry_sign: Sources/StringExtensions.swift#L57: ‘count’ is unavailable: there is no universally good answer, see the documentation comment for discussion
return self.count
:no_entry_sign: Sources/StringExtensions.swift#L305: ‘count’ is unavailable: there is no universally good answer, see the documentation comment for discussion
detector.enumerateMatches(in: text, options: [], range: NSRange(location: 0, length: text.count), using: {(result: NSTextCheckingResult?, _, _) -> Void in
:no_entry_sign: Sources/StringExtensions.swift#L67: ‘count’ is unavailable: there is no universally good answer, see the documentation comment for discussion
guard count > 0 else { return }
:no_entry_sign: Sources/StringExtensions.swift#L73: ‘count’ is unavailable: there is no universally good answer, see the documentation comment for discussion
guard count > 0 else { return self }
:no_entry_sign: Sources/StringExtensions.swift#L115: ‘count’ is unavailable: there is no universally good answer, see the documentation comment for discussion
guard count > 0 && (0..<length).contains(from) else { return }
:no_entry_sign: Sources/StringExtensions.swift#L123: ‘count’ is unavailable: there is no universally good answer, see the documentation comment for discussion
guard count > 0 && (0..<length).contains(from) else { return self }
:no_entry_sign: Sources/StringExtensions.swift#L132: ‘count’ is unavailable: there is no universally good answer, see the documentation comment for discussion
guard count > 0 else { return }
:no_entry_sign: Sources/StringExtensions.swift#L138: ‘count’ is unavailable: there is no universally good answer, see the documentation comment for discussion
guard count > 0 else { return self }
:no_entry_sign: Sources/StringExtensions.swift#L179: ‘count’ is unavailable: there is no universally good answer, see the documentation comment for discussion
guard count > 0 && (0..<length).contains(from) else { return }
:no_entry_sign: Sources/StringExtensions.swift#L187: ‘count’ is unavailable: there is no universally good answer, see the documentation comment for discussion
guard count > 0 && (0..<length).contains(from) else { return self }
:no_entry_sign: Sources/StringExtensions.swift#L379: use of unresolved identifier ‘NSAttributedStringKey’
let underlineString = NSAttributedString(string: self, attributes: [NSAttributedStringKey.underlineStyle: NSUnderlineStyle.styleSingle.rawValue])
8 Warnings
:warning: Sources/FloatingPointExtensions.swift#L17: result of operator ‘*’ is unused
for _ in 0..<places { divisor * 10 }
:warning: Sources/FloatingPointExtensions.swift#L16: variable ‘divisor’ was never mutated; consider changing to ‘let’ constant
var divisor: Self = 1
:warning: Sources/FloatingPointExtensions.swift#L30: result of operator ‘*’ is unused
for _ in 0..<places { divisor * 10 }
:warning: Sources/FloatingPointExtensions.swift#L29: variable ‘divisor’ was never mutated; consider changing to ‘let’ constant
var divisor: Self = 1
:warning: Sources/FloatingPointExtensions.swift#L17: result of operator ‘*’ is unused
for _ in 0..<places { divisor * 10 }
:warning: Sources/FloatingPointExtensions.swift#L16: variable ‘divisor’ was never mutated; consider changing to ‘let’ constant
var divisor: Self = 1
:warning: Sources/FloatingPointExtensions.swift#L30: result of operator ‘*’ is unused
for _ in 0..<places { divisor * 10 }
:warning: Sources/FloatingPointExtensions.swift#L29: variable ‘divisor’ was never mutated; consider changing to ‘let’ constant
var divisor: Self = 1

Generated by :no_entry_sign: Danger