[MUD-Dev] Languages

Jeff Kesselman jeffk at tenetwork.com
Sat May 24 15:46:47 CEST 1997


At 03:22 PM 5/24/97 PST8PDT, you wrote:
>[My apologies for continuing this thread - I'll keep it short.]
>
>[Jeff K;]
>
>:Remember that C++ gives you multiple ways to do inlines.
>:
>:Infact there is NO reason why C++ shoudl have ANY more voerhead then C IF
>:youvundertsnad what the compiler is doing and code to it correctly.
>
>Yes, but then the body of those routines has to be in the header file. This
>is the exact opposite of what information and implementation hiding is all
>about. I'm much more a fan of those than of C++'s wierd "object" stuff.

er... yer stuck back in C++1.0

There is an inline keyword that does the same thign in 2.0
But I DO still use the .h forma ctually when im writing accessors, which is
most of what yo uwill be calling.  I thin kin the trivial case of an
acessor its actually clearer then having someoen dig through the .cpp file
just to fidn out that its na inline reutrn of a member variable...

My older brother, who works for IBM's TJWatson Reseach Center and is
WONDERFUl for pithy oen liners has said...
"C++ make good programmers better, and bad programmers obvious."

I tend to agree with that.  It forces alot m,ore design thought early in
your projectand if you get the design wrong ya can't easily hack around it,
you need to revisit your design.
I happen to consider these GOOD properties in a language.

>:Typicly the reason C++ code ends up slower is due to mis-coding of
>:constructors by peopel who do NOT understand whats going on underneath.
>
>Sounds reasonable to me. So you suggest that C++ is a language that should
>only be used by programmers already trained on other languages, so that
>they can understand how to use C++ properly?

I sugges that, like any tool, those wh odon't udnerstadn what C++ is doing
probably shouldn't sue it, or at least not if they want optimal results.
Ever see a newbie pick up a hammer?  They use it in precisely the WRONG way
beause they are acting o nwhat they knwo from the past and don't yet
understand how the hammer works (they "choke up" on the handle.)

If yer gonan try to use a tool optimally ya better learn how it works first
or ya gonna hurt yerself.

JK


>
>--
>Chris Gray   cg at ami-cg.GraySage.Edmonton.AB.CA
>
>




More information about the mud-dev-archive mailing list