Path: csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!news.glorb.com!border3.nntp.dca.giganews.com!Xl.tags.giganews.com!border1.nntp.dca.giganews.com!nntp.giganews.com!local2.nntp.dca.giganews.com!nntp.earthlink.com!news.earthlink.com.POSTED!not-for-mail NNTP-Posting-Date: Sat, 10 Mar 2012 20:59:45 -0600 Message-ID: <4F5C1523.3C16@mindspring.com> Date: Sat, 10 Mar 2012 21:59:47 -0500 From: pete Reply-To: pfiland@mindspring.com Organization: PF X-Mailer: Mozilla 3.04Gold (WinNT; I) MIME-Version: 1.0 Newsgroups: comp.lang.c Subject: Re: i think i found References: <4F5BF051.303D@mindspring.com> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Lines: 38 X-Usenet-Provider: http://www.giganews.com NNTP-Posting-Host: 4.156.228.214 X-Trace: sv3-nMHuBleP/7uOyxlS7NYnnDkAE4VQeNiyHUgG3/cjegHcXI/LIptZkZhI6zPCjWvzeK+yhnuXl8GeFBR!1heiGP4hszQh1xViqhg1Oo6AdkuLZK7FxPuEpWe+zxetTmmbnHHLxDFQY1d072XoCJVm3wxATzt4!9gsNZNhr/GM= X-Abuse-and-DMCA-Info: Please be sure to forward a copy of ALL headers X-Abuse-and-DMCA-Info: Otherwise we will be unable to process your complaint properly X-Postfilter: 1.3.40 X-Original-Bytes: 2339 Xref: csiph.com comp.lang.c:18511 James Kuyper wrote: > > On 03/10/2012 07:22 PM, pete wrote: > > Barry Schwarz wrote: > ... > > Prior to C99, these words: > > > > ISO/IEC 9899: 1990 > > 6.6.6.4 The return statement > > > > A function may have any number of return statements, > > with and without expressions. > > > > If a return statement without an expression is executed, > > and the value of the function call is used by the caller, > > the behavior is undefined. > > Reaching the } that terminates a function is > > equivalent to executing a return statement without an expression. > > > > suggest that the use of the above function was defined in C90, > > as long as the code didn't use the return value. > > > > Both C99 and n1570, only have this much to say on this matter: > > > > A function may have any number of return statements. > > They didn't change that aspect of C in C99, > they only changed the way it was expressed. > 6.9.1p12: "If the } that terminates a function is reached, > and the value > of the function call is used by the caller, > the behavior is undefined.". Thank you. n1570 is the same way. -- pete