delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1997/06/02/17:29:54

Date: Mon, 2 Jun 1997 16:26:48 -0500 (CDT)
From: Adam W Lee <adalee AT sendit DOT sendit DOT nodak DOT edu>
Message-Id: <199706022126.QAA17191@sendit.sendit.NoDak.edu>
To: djgpp AT delorie DOT com
Subject: Re: Quake & Demos

>> Of course, C++, IMHO, is not for games, or anything that has to run
>> quickly.
>A  myth.
>C++ is as low level and fast exactly as C.

OK, I know I said I'd quit responding to this thread, but I can't help
myself... I just have to say, oh please, that's the dumbest thing I've
heard in a while.  HOW COULD C++ be as low level as C when it's C + OTHER
STUFF...  I don't see how you can possibly think that OOP and templates
don't provide overhead.

>The poster probably meant that the object oriented paradigm is not suitable
>enough.
>
>I disagree on that also. Sometimes good OO design results in an even faster
>code.
>Think about  virtual function calls vs chains of "if-else" or "switch"
>statements.
>C++ is a multi-paradigm language:
>  You want to write code in a C-like procedural manner ?  you can.
>  You want Object Oriented programming ? you got it.
>  You want Generic Programming <templates , STL>  ? you got it.
>
>plus, the compiler is always watching you. it won't let you do things that
>a C-compiler
>allows. Therefore , a C++ compiler is an even better way to learn C !.
>
>... and many more benefits.
>
>Eyal.

OK, I don't see why virtual functions would be any faster than a switch(),
a switch() statement is pretty damned fast if you ask me.

Secondly, why the hell would I code C in a C++ environment... That's like
writing a Pascal interpreter for DJGPP just so that I get the privilege of
typing something like gcc -o pascal.exe pascal.pas -lpascal or something
lame like that...  If you wanna right C, using a C++ pointer is dumb.

Third, I personally, and this obviously isn't everybody's opinion so
please don't even bother replying to it, I just want to say it, hate
generic programming and compilers that hold my hand...  If I wanted a
compiler that would hold it for me while I pee I'd still be using
QuickBASIC, because it even capitalized things for me. 

atomly

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019