Hacker News new | past | comments | ask | show | jobs | submit login

I get where you're coming from - but in my experience, the barrier is totally psychological. Objective C isn't that unusual a language - the syntax is a bit foreign, but nothing that takes more than a couple of days to wrap your head around.

You'll spend far more time getting to grips with Cocoa/Cocoa Touch.




the barrier is totally psychological

Of course it is. It's certainly not a physical barrier. But psychological or not, other languages don't have a similar barrier.


> other languages don't have a similar barrier

Lisps have the RPN psychological barrier. Python has the significant whitespace psychological barrier. etc. Any language can present someone with some psychological barrier.

I think the OP's strongest point was, Objective-C the language is pretty trivial to learn quickly (after all, it's just C with message passing). You'll spend far longer trying to learn the Cocoa APIs than you will spend learning Objective-C-the-language.

For instance, I decided to try to learn swift and SpriteKit at the same time. I spent far longer looking up methods on SKSpriteNode than I did looking up language constructs. (i.e. I assumed "let" was the same as in ES6 and couldn't figure out why the compiler was mad.)


Okay, I meant more that there's not a skills barrier in terms of actually learning to use the language. The syntax can be intimidating, but once you've spent a couple of hours with it, it's not an issue any more.

It's far more difficult to get to grips with how the APIs work.


That's my problem. I can't even find the entry point for this application. Looking at AppDelegate.swift I see an unused var (window) and that's it.


@UIApplicationMain is the key there, from what I can see. An Objective C iOS app typically includes a main.m entry point which calls UIApplicationMain and passes the AppDelegate. This seems to have been removed in favour of what Swift is calling a "declaration attribute", which presumably does the same thing.

In this sense, the code is even less clear than the Objective C implementation.


They removed the need for main by making global scope the entry point.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: