Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Posting-Version: version B 2.10 5/3/83; site bbncca.ARPA Path: utzoo!linus!bbncca!keesan From: keesan@bbncca.ARPA (Morris Keesan) Newsgroups: net.lang.c Subject: Re: inconsistency in C manual Message-ID: <631@bbncca.ARPA> Date: Mon, 19-Mar-84 18:32:51 EST Article-I.D.: bbncca.631 Posted: Mon Mar 19 18:32:51 1984 Date-Received: Tue, 20-Mar-84 01:35:00 EST References: <3623@utzoo.UUCP> Organization: Bolt, Beranek and Newman, Cambridge, Ma. Lines: 35 ---------------------------- The C Language section of the System V Programming Guide corrects the incosistency introduced into the manual in V7 by the addition of functions returning structs and unions. From the Guide, under "EXPRESSIONS/A" A primary expression followed by a dot followed by an identifier is an expression. The first expression must be a structure or a union, and the identifier must name a member of the structure or union. The value is the named member of the structure or union, and it is an lvalue if the first expression is an lvalue. Also, from the System V Transition Aids, 3.2 Access to a Member of a Returned Structure or Union. Now that the language allows structure and union assignments a bug was uncovered in the compiler regarding the immediate access of members of the returned structure or union. An example of such a construct is: x = f().a; where f() is a function returning a structure that has a member element of "a". This bug has been identified and removed from the compiler. Does anybody have any idea what the referred-to bug is? -- Morris M. Keesan {decvax,linus,wjh12,ima}!bbncca!keesan keesan @ BBN-UNIX.ARPA