[swift-evolution] SR-1246: Inconsistent naming and declaration of String & NSString derivative properties and functions

Gwendal Roué gwendal.roue at gmail.com
Sat Apr 23 05:33:26 CDT 2016


I have been advised to post the bug report https://bugs.swift.org/browse/SR-1246 on swift-evolution, so here it is:

In the latest swift-DEVELOPMENT-SNAPSHOT-2016-04-12-a.xctoolchain (master), there are inconsistencies in the following declarations:

    extension String {
        public func lowercased() -> String
        public func uppercased() -> String

    extension NSString {
        public var uppercased: String { get }
        public var lowercased: String { get }
        public var capitalized: String { get }
        public var localizedUppercase: String { get }
        public var localizedLowercase: String { get }
        public var localizedCapitalized: String { get }

We see that we have sometimes properties, sometimes functions, and they sometimes end in -ed, and sometimes not.

Gwendal Roué

More information about the swift-evolution mailing list