From owner-cvs-sys Thu Oct 3 02:10:29 1996 Return-Path: owner-cvs-sys Received: (from root@localhost) by freefall.freebsd.org (8.7.5/8.7.3) id CAA16680 for cvs-sys-outgoing; Thu, 3 Oct 1996 02:10:29 -0700 (PDT) Received: from godzilla.zeta.org.au (godzilla.zeta.org.au [203.2.228.19]) by freefall.freebsd.org (8.7.5/8.7.3) with ESMTP id CAA16664; Thu, 3 Oct 1996 02:10:23 -0700 (PDT) Received: (from bde@localhost) by godzilla.zeta.org.au (8.7.6/8.6.9) id TAA08440; Thu, 3 Oct 1996 19:04:51 +1000 Date: Thu, 3 Oct 1996 19:04:51 +1000 From: Bruce Evans Message-Id: <199610030904.TAA08440@godzilla.zeta.org.au> To: bde@zeta.org.au, phk@critter.tfs.com Subject: Re: cvs commit: src/sys/i386/isa syscons.c Cc: cvs-all@freefall.freebsd.org, CVS-committers@freefall.freebsd.org, cvs-sys@freefall.freebsd.org, jkh@freefall.freebsd.org, peter@spinner.dialix.com, sos@FreeBSD.org Sender: owner-cvs-sys@FreeBSD.org X-Loop: FreeBSD.org Precedence: bulk >One "semi-clean" way of doing it would have been to add a hack to >gcc so that args named __unused_* wasn't complained about, then you >could: > int foo (char * _unused_1) > { > } >to suppress it. This would still require changing thosands of functions. >>The unused attribute doesn't work right in typedefs. Otherwise we >But that's because you cannot say > > sy_call_t > read > { > if (proc != curproc) > ... > } > >(Which I think is a bug in C btw.) That's because the names in prototypes are unused :-). The attributes could be used. >You don't use the typedef when you declare the function. Yes you do. The above is a definition, not a declaration :-). >That's why I have used the SYSCTL_HANDLER_ARGS solution for sysctl. I don't like macros like these, although I introduced similar ones for ddb functions. Bruce