user10595407
user10595407

Reputation:

What is the difference between String and NSMutableString?

What is the difference between String and NSString?

Upvotes: -2

Views: 98

Answers (1)

Duncan C
Duncan C

Reputation: 131501

String is a Swift native type, and uses value semantics.

NSMutableString is a Foundation Class object that is "toll-free-bridged" with the Swift String type. As a Class object it uses reference semantics.

The NSMutableString class has a few methods that the Swift String type does not.

Upvotes: 2

Related Questions