Added Character.toInt
This commit is contained in:
parent
ea80efe0ed
commit
a9cd633ecb
|
@ -11,6 +11,10 @@ import Foundation
|
|||
extension Character {
|
||||
/// EZSE: Converts Character to String //TODO: Add to readme
|
||||
public var toString: String { return String(self) }
|
||||
|
||||
/// EZSE: If the character represents an integer that fits into an Int, returns the corresponding integer.
|
||||
///TODO: Add to readme
|
||||
public var toInt: Int? { return Int(String(self)) }
|
||||
}
|
||||
|
||||
|
||||
|
|
Loading…
Reference in New Issue