Path: csiph.com!fu-berlin.de!uni-berlin.de!individual.net!not-for-mail From: Ian Collins Newsgroups: comp.lang.c Subject: Re: Octal Date: Mon, 2 Jan 2017 08:33:38 +1300 Lines: 22 Message-ID: References: <58641791.15528406@news.xs4all.nl> <58642673.19338234@news.xs4all.nl> <5864306d.21892234@news.xs4all.nl> Mime-Version: 1.0 Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit X-Trace: individual.net eL1+tsBka6KgaSYn7MGBbQKt8jtrSVXU4pRJGwbMJAWJxuOCqO Cancel-Lock: sha1:BmSkb8RPuElGngH0Iw+acd2eMwo= User-Agent: Mozilla/5.0 (X11; SunOS i86pc; rv:38.0) Gecko/20100101 Thunderbird/38.5.1 In-Reply-To: Xref: csiph.com comp.lang.c:100805 On 01/ 2/17 04:00 AM, David Brown wrote: > On 30/12/16 16:55, BartC wrote: >> On 30/12/2016 14:00, David Brown wrote: >>> On 30/12/16 14:04, BartC wrote: >> >>>> Not even 'Unused parameter'? >>> >>> int foo(int a) { >>> (void) a; >>> return 123; >> >> Ugly. > > It is less ugly than incorrect code - and code that does not use the > parameters is, IME at least, usually wrong or at least an indication of > inefficiency somewhere. It is not /always/ wrong, of course, but usually. I wonder why C hasn't adopted the simple rule from C++: if a parameter isn't going to be used, don't give it a name. -- Ian