Home
Thursday, May 25, 2017
5:33:55 AM
Users online: 0   You are here >> Home > Programming

Forums | Programming Forums search
Forum FAQ
   
  1 | 2 Next Page 
I hate objective C
superfireydave 
18/3/08 8:35:52 PM
Titan

One of my classes this semester is a subject about OOP.
The language for it is objective C. I hate it >_<.

Thankfully, I'm also able to do it in C++ which I already know pretty well so I'm saved from an untimely stress and annoyance related death.


Does anyone actually use objective C in the real world? If so, what for? As far as my limited knowledge goes, it's effectively a teaching language, but I don't understand why they use it if it's so convoluted and distanced from almost every other related programming language >_<

-----
Mreow?

makaveli 
18/3/08 9:24:44 PM
Overlord
isnt objective c used in the apple iphone sdk?

-----

nickeax 
18/3/08 9:38:54 PM
Banned

I've heard of it, but never used it. You can do some pretty neat stuff with plain C through sub classing and function pointers. It's more work, but you can kind of make your own C++. :-)

Well, not really...

-----
George Allen Miles, Jr. (September 5, 1947 – February 26, 2008)

I can teach you guitar for free:
http://www.guitaraustralia.com/

superfireydave 
19/3/08 12:21:02 AM
Titan

Quote by makaveli
isnt objective c used in the apple iphone sdk?


I hope not =P
If it is - good thing I don't ever plan to develop for them >_<

Nickeax - Yeah, ordinary C is fine; I prefer the scope of C++ and am more familiar with it thought - but objective C just plain sucks >_<

-----
Mreow?

freespace 
19/3/08 1:35:20 AM
Hero
Titan


Spoken like some one who never realised C++ sucks and obj-c is superior in a million ways.

There is a reason Apple chose obj-c as its principle development language.

-----
By perseverance the snail reached the ark.

http://www.shuningbian.net - blog
http://anonshare.pictorii.com - share files anonymously
http://dailydiscovery.b3ta.org - learn something new
its f reespace damn it!

superfireydave 
19/3/08 3:11:51 AM
Titan

I like C++ =P Classes, being able to allocate and control memory, being able to fine tune various parts really easily appeal to me. That, and I find it makes sense and follows a similar syntax and way of thinking to many other programming languages.

Objective C on the other hand seems completely different, and I don't understand its benefits over the others. I'm happy for you to elaborate, but at the moment I can't see a use for me to use it at all =P

-----
Mreow?

dave_blob 
19/3/08 11:06:44 AM
Champion

the obj-c syntax is vomit worthy, although i hear new versions use dot notation which would be a large improvement.

-----
Your comeback shames me

Phelan:
You exist. You are born and you die. That's it.
What matters is life before death - enjoy your time here, be nice to others and have some fun.

nickeax 
19/3/08 11:45:17 AM
Banned

I hope people are being objective here?

-----
George Allen Miles, Jr. (September 5, 1947 – February 26, 2008)

I can teach you guitar for free:
http://www.guitaraustralia.com/

freespace 
20/3/08 2:36:13 PM
Hero
Titan


Quote by superfireydave
I like C++ =P Classes, being able to allocate and control memory, being able to fine tune various parts really easily appeal to me. That, and I find it makes sense and follows a similar syntax and way of thinking to many other programming languages.

Are you sure you are talking about C++? Those exact same things can be said for objective-c, and it would be truer in my books.

I honestly don't understand why people dislike objective-c because it takes a different (and better approach) to true object oriented programming, and why they have such a big gripe about it not using the dot notation.

From where I am, people are disliking objective-c purely because they are being confronted with a new way of doing things, which is different to their old way of doing things. Instead of learning to do things the objective-c way, they try to do in objective-c what they do in their favourite language, and when they fail, they come to the conclusion "objective-C sucks".

What a waste. C++ is indeed one of the worst thing to have ever happened to programming, much like basic.

-----
By perseverance the snail reached the ark.

http://www.shuningbian.net - blog
http://anonshare.pictorii.com - share files anonymously
http://dailydiscovery.b3ta.org - learn something new
its f reespace damn it!

superfireydave 
20/3/08 3:21:38 PM
Titan

Well; from my perspective I can program a game in C++ and optimise it to run as well as it possibly can. I can't do that in Objective C because there's a completely new syntax and slightly new way of thinking.

Yes, neither enforce a paradigm upon you - which is nice; But the syntax really does shit me to tears.

I asked you to explain what it does better then C++; you still haven't answered me except saying you dislike C++ - which is fine - except that's where the majority of good game engines are.

-----
Mreow?

freespace 
20/3/08 4:20:51 PM
Hero
Titan


Quote by superfireydave
Well; from my perspective I can program a game in C++ and optimise it to run as well as it possibly can. I can't do that in Objective C because there's a completely new syntax and slightly new way of thinking.

Which is not a fault of the language. If you started with objective-c, you would have the same view towards C++

Yes, neither enforce a paradigm upon you - which is nice; But the syntax really does shit me to tears.
I think you missed my point entirely. The point is you are used to doing things the C++ way. When you attempt apply the same technique in objective-c, it fails. As a result, you think objective-c sucks. That was my point.

I asked you to explain what it does better then C++; you still haven't answered me except saying you dislike C++ - which is fine - except that's where the majority of good game engines are.
Popularity does not mean its better. I am sure you can think of many examples.

How is objective-c better? For one it has Real OO implemented using message passing. This means you don't call methods, you send object messages, and if the object can respond, it will, otherwise it won't. This has enormous power because you can call an arbitrary method on an arbitrary object in runtime, allowing for all sorts of cool tricks, like replacing a class in runtime entirely without even access to the source code. Tricks like these are used quite a lot in OS X to implement and extend applications. See FScript.

Because of the above, objective-c has runtime binding, one of the advantage of which is that if the base class changes, it won't break the subclasses. It means if you are writing code against a library, and later that library changes, your code won't break just because you subclassed a library class, and now the class signatures are different.

And then there is proxies and categories, which allows you to extend the superclass without modifying the library the superclass is in.

Objective-c at least has some control over memory in the way of reference counting. It is part of the language. In C++ you need the boost library.

In short, objective-c doesn't suck any more than C++ sucks, and I only wish you won't confuse your own difficulties with dealing with a new language with a language's short comings. I hope to additionally counter your thread's accusation that objective-c sucks. To me, objective-c is the best of the breed of the c-esque OO languages.

-----
By perseverance the snail reached the ark.

http://www.shuningbian.net - blog
http://anonshare.pictorii.com - share files anonymously
http://dailydiscovery.b3ta.org - learn something new
its f reespace damn it!

superfireydave 
20/3/08 5:37:48 PM
Titan

Thank you =P
I still think it sucks though =P but I now can appreciate why you'd use it; which is really what I meant to ask because I'd never encountered it before.

And as for my learning difficulties, they were over the space of an hour =P If I can't get into it within that space of time I figure I wont be able to keep getting into enough for me to actually want to learn. I'm not *that* dumb, I swear!


Edited by superfireydave: 20/3/2008 05:38:04 PM

-----
Mreow?

freespace 
20/3/08 10:07:18 PM
Hero
Titan


Quote by superfireydave
Thank you =P
I still think it sucks though =P but I now can appreciate why you'd use it; which is really what I meant to ask because I'd never encountered it before.

And as for my learning difficulties, they were over the space of an hour =P If I can't get into it within that space of time I figure I wont be able to keep getting into enough for me to actually want to learn. I'm not *that* dumb, I swear! Edited by superfireydave: 20/3/2008 05:38:04 PM

Another fine mind ruined by C++.

-----
By perseverance the snail reached the ark.

http://www.shuningbian.net - blog
http://anonshare.pictorii.com - share files anonymously
http://dailydiscovery.b3ta.org - learn something new
its f reespace damn it!

Girvo 
21/3/08 2:57:01 PM
Immortal

Freespace likes Ruby. Don't judge him.


:P

-----
[No Heroes] is the artistic antithesis of that sinking world; a thorn in the side of their beast. It's for those who move mountains one day at a time. It's for those who truly understand sacrifice. In our world of enemies, we will walk alone...

freespace 
21/3/08 3:41:23 PM
Hero
Titan


Quote by Girvo
Freespace likes Ruby. Don't judge him.
:P

Wrong on two accounts!

First, it is freespace, no Freespace.

Second, ruby fanboi is zephr, not I :P

-----
By perseverance the snail reached the ark.

http://www.shuningbian.net - blog
http://anonshare.pictorii.com - share files anonymously
http://dailydiscovery.b3ta.org - learn something new
its f reespace damn it!

superfireydave 
21/3/08 5:16:39 PM
Titan

Well, when the engines I've been working with port to Objective C, I'll have reason to use it :)
Until then I'll stick with normal C, or C++, or C# =P

-----
Mreow?

Girvo 
22/3/08 12:51:01 AM
Immortal

God I failed so hard! Could've sworn you used RoR? Ah well. If you want stupid syntax, Ruby is your man/woman/robot.

*facepalm

-----
[No Heroes] is the artistic antithesis of that sinking world; a thorn in the side of their beast. It's for those who move mountains one day at a time. It's for those who truly understand sacrifice. In our world of enemies, we will walk alone...

dave_blob 
24/3/08 5:41:38 PM
Champion

Quote by Girvo
God I failed so hard! Could've sworn you used RoR? Ah well. If you want stupid syntax, Ruby is your man/woman/robot.

*facepalm



stupid syntax?!

/kills givro in the heart

Nicest syntax out of any langauge ive used (C,C++,lisp,ml,java,php,perl)

What do you hate about it? There are things that annoy the shit out of me in ruby, but syntax is not one.

EDIT: freespace
Cheers for your summary on Obj C, interesting.

Although, to pick bones, I dont think its fair to say all criticisms of syntax in language A arise just because people are used to programming in langauge B.
Some syntaxes can just plain suck, or contain aspects that suck objectively rather than subjectivly.

In a totally contrived and silly example, say I made a language where every variable had to be parenthised in 7 curly braces. Even though everyone is used to other languages than this one, it would still be fair to say its syntax sucks.




Edited by dave_blob: 24/3/2008 05:49:54 PM

-----
Your comeback shames me

Phelan:
You exist. You are born and you die. That's it.
What matters is life before death - enjoy your time here, be nice to others and have some fun.

Girvo 
25/3/08 12:00:34 AM
Immortal

Syntax is just not what I'm used to. I'm picky ;)

Mind you, I use PHP on a daily basis. Try using THAT syntax. D:

-----
[No Heroes] is the artistic antithesis of that sinking world; a thorn in the side of their beast. It's for those who move mountains one day at a time. It's for those who truly understand sacrifice. In our world of enemies, we will walk alone...

dave_blob 
25/3/08 10:12:26 AM
Champion

Quote by Girvo
Syntax is just not what I'm used to. I'm picky ;)

Mind you, I use PHP on a daily basis. Try using THAT syntax. D:



I have. Its probably fair to say that objectivly, PHP is an ugly mess.

A very usefull mess, but a mess nonetheless.

-----
Your comeback shames me

Phelan:
You exist. You are born and you die. That's it.
What matters is life before death - enjoy your time here, be nice to others and have some fun.

  1 | 2  | Next Page 
Forums | Programming