Hacker News new | ask | show | jobs
by mekster 1574 days ago
It seems you like some ancient language which can't even concatenate a string without writing this dull statement with bunch of symbols.

  NSString *string1 = @"Some";
  NSString *string2 = @" string";
  NSString \*string3 = [string1 stringByAppendingString:string2];
Not to mention it didn't have ARC back in the days.

For sake it was built nearly 40 years ago. Not sure if there's any room to question why Apple and devs wanted a new language.

I was amazed why anyone would want to use this language before Swift but people didn't have a choice.

There were efforts like MacRuby.

2 comments

To be fair, while Swift includes nice convenience methods for strings, the new API comes with a considerable cost:

https://www.mikeash.com/pyblog/friday-qa-2015-11-06-why-is-s...

That article is from 2015. A lot has changed, though some people still complain.
Doubtful that the technical underpinnings of the API have changed all that much since 2015.
They very much have.
ARC has been there for almost a decade now. Also if you wish to do heavy string concatenation, please use a NSMutableString and you can simply do: [string1 appendString:string2];

It is amazing that people forget to simply use the right tool for the right job and blame the PL instead.