[/QUOTE]
I see, I did not think of it that way.
[quote="Sydde, post: 11799466"]Your list looked to me like a description of Objective-C as seen from a C++ perspective - in other words, focussed on Objective-C's characteristics.
In Objective-C, an object is a pointer. The compiler will spit up on you if you try to declare an object that is not a pointer (static allocation). The stack is not the only place you might declare an object. If it is a global, or an instance variable in a class definition, a pointer is what is expected.[/QUOTE]
Yes, but again that is the point I was making. The same is true in C++ and in C. You need to create a pointer, which will point to the object allocated on the heap.
[quote="Sydde, post: 11799466"]
I am not particularly familiar with C++, but from what I understand, an object is not significantly different from the struct that defines its instance. Objective-C attempts to apply opacity to its methodology. You are not supposed to be able to "reach inside" an NSObject from "outside" it. From what I understand of C++, if your code has the definition of a given object's instance struct, it can directly manipulate the instance content, whereas in Objective-C your code is expected to rely on a given object's methods to access and/or manipulate its content. You can work around these Objective-C constraints, but in that case, why not just use plain C in the first place?
[/QUOTE]
That is exactly the same in these languages (and OOP in general), an object is nothing but a glorified struct that has function pointers and a this/self pointer available on the inside. The other significant difference is that a struct has public members by default but in a class they are private by default.
You could imitate a class in C like this, except the this/self pointer.
[CODE]
struct Object {
int iVar;
void (*setValue)(int);
int (*getValue)();
};