Is Objective C a variant of C? Why isn't it discussed on this site?
I noticed that there aren't forums dedicated to learning it.
Is Objective C a variant of C? Why isn't it discussed on this site?
I noticed that there aren't forums dedicated to learning it.
Except of course if you are writing software for iPhone - in which case Objective C is basically the only choice.
--
Mats
Compilers can produce warnings - make the compiler programmers happy: Use them!
Please don't PM me for help - and no, I don't do help over instant messengers.
And if you're going to develop for a portable device, Java for years to come :-)
Not everything that can be counted counts, and not everything that counts can be counted
- Albert Einstein.
No programming language is perfect. There is not even a single best language; there are only languages well suited or perhaps poorly suited for particular purposes.
- Herbert Mayer
Obj-C is a curious language, a spawn of C and Smalltalk, slightly older than C++. (C++ is a spawn of C and Simula.) The main differences between Obj-C and C++ are:
1) Obj-C's object system doesn't try to meld with C. The syntax is completely different from what a C programmer is used to, giving Obj-C a very weird look overall. C++ tries to meld with the C syntax. The result is better compatibility of Obj-C with older C code (no new keywords, for example), at the cost of weird syntax.
2) Obj-C is based on interfaces ("protocols") and implementations, with every object on the heap. You have "messages" instead of functions, and I believe the actual action taken upon message receipt is somewhat dynamic. C++ goes the minimal way, by making classes an extension of C structures.
All the buzzt!
CornedBee
"There is not now, nor has there ever been, nor will there ever be, any programming language in which it is the least bit difficult to write bad code."
- Flon's Law
AFAIK, isn't Objective-C a strict superset of ANSI C, that is, any ANSI C code is also valid Objective-C code (which cannot be said of C++)?Obj-C's object system doesn't try to meld with C. The syntax is completely different from what a C programmer is used to, giving Obj-C a very weird look overall. C++ tries to meld with the C syntax. The result is better compatibility of Obj-C with older C code (no new keywords, for example), at the cost of weird syntax.
operating systems: mac os 10.6, debian 5.0, windows 7
editor: back to emacs because it's more awesomer!!
version control: git
website: http://0xff.ath.cx/~as/
I believe it is.AFAIK, isn't Objective-C a strict superset of ANSI C
ANSI was faster They standardized it in 1989, ISO in 1990. So C89 is ANSI C, whereas C90 is ISO C.Why does everyone mention ANSI C?
ISO C is what it is and what it should be.
(Not that there's any difference.)
All the buzzt!
CornedBee
"There is not now, nor has there ever been, nor will there ever be, any programming language in which it is the least bit difficult to write bad code."
- Flon's Law
Sure, but when ISO standardized it, it means that ANSI should get kicked out of the loop.
That is why I always refer to it as C90. Internationalization is important!
So ISO beats ANSI by horse-lengths.
The best would be if there was no ANSI and only ISO.