Hacker News new | ask | show | jobs
by marcosdumay 2096 days ago
You seem to have experience only on languages where strings are immutable, and objects are always mutable. Those properties are not universal.

And yet, despite correctly assessing the problem, you insist on fighting objects instead of mutability.

1 comments

one of the interesting things in cocoa/foundation is the types are all objects, but they make a big distiction between NSArray and NSMutableArray, same with strings, dictionaries and many other objects

to make things mutable you have to clone them as such and i cant really think of a single api in cocoa/foundation that vends a mutable array or string...

i think its a very good point...