🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: net.bugs.2bsd
Article #125

Re: Uses for non-unique names in structu - (nf)

#125
From: jab
Date: Sun, 25 Dec 1983 03:41
26 lines
1423 bytes
#R:mit-eddi:-100600:uokvax:17600001:000:877
uokvax!jab    Dec 22 13:00:00 1983


In response to the remark that "V7 and earlier complained if you had
non-unique member names (for different structures), regardless of type":

	No, the compiler accepted this IFF the duplicate names were the
	same type and offset into the structure.

I like the notion that for "struct gorp", all the members begin with "g_":

	struct gorp {
		int g_value;	/* value of this gorp */
		struct gorp *g_next;	/* pointer to next gorp in list */
		struct gorp *g_prior;	/* pointer to previous gorp in list */
	};
This makes reading the code a lot easier, really.

I believe that the compiler REALLY SHOULD honor the construct that allows
you to have non-unique member names, but since there's no "standard" anywhere,
who's to say? (And DON'T point me to the K&R book. The only thing that tells
me what is valid to the C compiler is the source, sad to say.)

	Jeff Bowles
	Lisle, IL
Technical Details
Message-ID: <4696@uiucdcs.UUCP>
Path: arc1-ca.pugleaf.net!utzoo!linus!philabs!seismo!harpo!ihnp4!inuxc!pur-ee!uiucdcs!parsec!ctvax!uokvax!jab

Show Full Headers
Complete Article Headers
Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP
Path: arc1-ca.pugleaf.net!utzoo!linus!philabs!seismo!harpo!ihnp4!inuxc!pur-ee!uiucdcs!parsec!ctvax!uokvax!jab
From: jab@uokvax.UUCP
Newsgroups: net.bugs.2bsd
Subject: Re: Uses for non-unique names in structu - (nf)
Message-ID: <4696@uiucdcs.UUCP>
Date: Sat, 24-Dec-83 22:41:23 EST
Article-I.D.: uiucdcs.4696
Posted: Sat Dec 24 22:41:23 1983
Date-Received: Fri, 6-Jan-84 01:39:20 EST
Lines: 26