Talk About Network

Google


Register and Login
Nick
Password
Register create new account Sign up is FREE and you can post replies, new topics, bookmark posts and more!
Recover lost password


Programming > C Moderated > Re: Need a GURU...
Latest [ Topics | Posts ] Archive Post A New Topic Post a Reply
<< Topic < Post Post 4 of 9 Topic 1044 of 1134
Post > Topic >>

Re: Need a GURU!!! I'm stuck.

by =?UTF-8?B?SGFucy1CZXJuaGFyZCBCcsO2a2Vy?= <HBBroeker@[EMAIL PROTECTED] > Mar 20, 2008 at 01:09 AM

Keith Thompson wrote:

> In any case, if you want a typedef for a struct type, there's no good
> reason to use very different names for them.

Well, that would depend on whether trying to satisfy externally enforced 
coding rules should be considered a "good reason", and whether different 
prefixes, suffixes, capitalizations or peppering the whole thing with 
separators like '_' is seen as making them "very" different ;-)

> But a lot of programmers like being able to use a one-word name rather
> than having to repeatedly type (and read) the "struct" keyword.

The additional benefit is that as long as you're manipulating the whole 
object, rather than its individual fields, the typedef avoids having to 
spell out that the thing is (currently) a struct.  Which would mean just 
that bit less of editorial work next time the thing get changed from a 
struct to some other type.  IMHO, C++'s "implied typedef" was exactly 
the right move here.
-- 
comp.lang.c.moderated - moderation address: clcm@[EMAIL PROTECTED]
 -- you must
have an appropriate newsgroups line in your header for your mail to be
seen,
or the newsgroup name in square brackets in the subject line.  Sorry.
 




 9 Posts in Topic:
Need a GURU!!! I'm stuck.
Chris LaVelle <cjlavel  2008-02-17 12:04:40 
Re: Need a GURU!!! I'm stuck.
=?ISO-8859-1?Q?Hans-Bernh  2008-03-08 12:19:59 
Re: Need a GURU!!! I'm stuck.
Keith Thompson <kst-u@  2008-03-17 15:18:58 
Re: Need a GURU!!! I'm stuck.
=?UTF-8?B?SGFucy1CZXJuaGF  2008-03-20 01:09:51 
Re: Need a GURU!!! I'm stuck.
Barry Schwarz <schwarz  2008-03-08 12:20:10 
Re: Need a GURU!!! I'm stuck.
David Thompson <dave.t  2008-03-17 15:23:28 
Re: Need a GURU!!! I'm stuck.
Carl Barron <cbarron41  2008-03-08 12:20:22 
Re: Need a GURU!!! I'm stuck.
Joel Yliluoma <bisqwit  2008-03-08 12:20:33 
Re: Need a GURU!!! I'm stuck.
hnarkaytis@[EMAIL PROTECT  2008-03-08 12:21:14 

Post A Reply:
  Go here to Signup

AddThis Feed Button


About - Advertising - Contact - Frequently Asked Questions - Privacy Policy - Terms of Use - Signup

Contact
tan12V112 Sat Jul 26 3:45:58 CDT 2008.