Article View: rec.games.programmer
Article #2016Re: Should I learn C or C++ first?
From: Rainer Deyke
Date: Mon, 28 Aug 1995 23:24
Date: Mon, 28 Aug 1995 23:24
30 lines
1755 bytes
1755 bytes
Pete Becker (pete@borland.com) wrote: : In article <41ki32$p4t@deyke3.fc.hp.com>, rainer@deyke3.fc.hp.com says... : >Well, I prefer explicit types because they are so much clearer. I : >consider typedefs to be extremely bad style, but I suppose it is a : >matter of personal preference. The point I was making is that typedefs : >aren't necessary in C any more than in C++. Sorry if I offended you. : "So much clearer"? Really? Which of these two is easier to read? : typedef void (*sigfunc)(int); : sigfunc signal(int sig, sigfunc func); : or : void (*signal(int sig, void (*func)(int)))(int); Well, for the first you will need to know what sigfunc is defined as before you understand it, while the second is simply obvious to any programmer above the beginner level. : I am not an idiot, and I will always use the first form rather than the : second. Good code is written clearly, not cleverly. Well, what's so clear about 'sigfunc'? -- +----------------------------------------------+ | Rainer Deyke (rainer@mdddhd.fc.hp.com) | | "The Earth shall inherit the meek" - Carcass | +----------------------------------------------+
Technical Details
Message-ID:
<41tj89$2hn@deyke3.fc.hp.com>Path:
arc1-ca.pugleaf.net!fc.hp.com!hpfcmdd!deyke3!rainerReferences:
<40o2ee$aqp@deyke3.fc.hp.com> <DDIE24.Hqw@info.uucp> <41ki32$p4t@deyke3.fc.hp.com> <41nga5$qau@druid.borland.com>Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!fc.hp.com!hpfcmdd!deyke3!rainer From: rainer@deyke3.fc.hp.com (Rainer Deyke) Newsgroups: rec.games.programmer,comp.lang.c++ Subject: Re: Should I learn C or C++ first? Followup-To: rec.games.programmer,comp.lang.c++ Date: 28 Aug 1995 23:24:57 GMT Organization: my basement Message-ID: <41tj89$2hn@deyke3.fc.hp.com> References: <40o2ee$aqp@deyke3.fc.hp.com> <DDIE24.Hqw@info.uucp> <41ki32$p4t@deyke3.fc.hp.com> <41nga5$qau@druid.borland.com> Reply-To: rainer@mdddhd.fc.hp.com NNTP-Posting-Host: deyke3.fc.hp.com X-Newsreader: TIN [version 1.2 051093BETA PL3]