Re: Future Objective-C changes
Re: Future Objective-C changes
- Subject: Re: Future Objective-C changes
- From: Oscar Morales Vivó <email@hidden>
- Date: Fri, 16 May 2003 15:10:47 +0200
I'm bored at work, so I'll write...
Keep in mind where I'm coming from. I write for the most part Cocoa
fron-ends to big chunks of C++ code. And guess what, I like both. For
the most part I agree with the statement below, but just don't overdo
it. I see statements like 'you don't need that feature from language B,
use discipline while programming in language A' and I think 'you don't
need structured programming, use discipline while programming in
assembly'. Language features (at least modern language ones) are
supposed to be there for the convenience of the programmer. Some fail
miserably, some are not used properly and/or are overused, and some are
an annoyance (90% of my gripes with C++ stem from its C heritage). C++
has its place in the world. It's just not programming application UI
code. Objective-C does a far better job there.
About what he asks to be included in Objective-C, most of it is really
unnecessary due to the different programming paradigm of Cocoa. But not
100% so. Function overloading is nothing more than syntactic sugar. I
think it might be included in Objective-C as it's a compile time
feature, but it would be more trouble than it's worth (as the dynamic
nature of Objective-C objects will probably cause unexpected functions
to be called on occasion). Besides, the only real use of function
overloading in C++ is for template programming, and that is also
unnecessary in Objective-C (but for what I'll comment later).
The need for template programming as has been stated elsewhere is very
small in Objective-C if any at all. It is possible to do very generic
programming thanks to the selector mechanism, and I think someone
around there had implementations of Obj-C equivalents of the C++ STL
<algorithm> around (which I'd appreciate if someone linked me to. I've
been meaning to check those for a while now). The only reasonable use I
see for templates in Obj-C is for type-safety syntactic sugar, as per
the typed containers that have been described before. I think it's a
similar approach to the one the Java people want for 1.5 (which we
won't discuss here, thanks ;).
Personally, I'd have absolutely no problems with namespaces in
Objective-C. They don't change the generated code, just an extra
encapsulation mechanism which would be far more usable in C++ were it
not for the fact that the feature has been implemented oh so recently
in commercial compilers.
And that's it for today.
On Friday, May 16, 2003, at 14:28 Europe/Madrid, Marco Scheurer wrote:
On Friday, May 16, 2003, at 09:05 AM, Jeff Disher wrote:
Why does everyone insist on polluting the Objective-C language so
much? None of what anyone has asked for in this thread or the
similar thread on Omni-Dev a while back would actually add power to
the language or any other meaningful qualities.
The problem is that people want Obj-C to be C++. I don't understand
this issue and I think that you would realize that none of what you
are referring to is needed if everyone decided to learn Obj-C
paradigms instead of trying to shoe-horn C++ paradigms into it. If
you want something ugly to code in that badly, use Obj-C++.
[...]
Sorry, I just felt the need to state my views on this since this
issue keeps coming up,
Agreed 100%. Keep Objective C small, simple, and powerful.
Marco Scheurer
Sen:te, Lausanne, Switzerland http://www.sente.ch
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.
/*
Oscar Morales Vivs
Eternal Computer Science Student. Master of C++ Templates. Cocoa Nut.
Computer Graphics Illuminati. UI Guru in Training. Dabbler in all
things CS and most which are not.
Web stuff:
http://homepage.mac.com/oscarmv/index.html
*/
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.