Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 6 Dec 1998 17:27:44 +0100
From:      J Wunsch <j@uriah.heep.sax.de>
To:        freebsd-hackers@FreeBSD.ORG, cvs-committers@FreeBSD.ORG
Subject:   Re: getting to -Wunused
Message-ID:  <19981206172744.53389@uriah.heep.sax.de>
In-Reply-To: <199812060032.QAA01400@bubba.whistle.com>; from Archie Cobbs on Sat, Dec 05, 1998 at 04:32:44PM -0800
References:  <199812060032.QAA01400@bubba.whistle.com>

next in thread | previous in thread | raw e-mail | index | archive | help
As Archie Cobbs wrote:

>  (d) Static functions that are declared and defined, but never used:
> 
>      (i)  Some of these are defined #ifdef DDB, and are clearly meant
>           for debugging purposes (they're not used, but they're handy
>           to call from the debugger to print out stuff, etc). These
>           are "legitimate" unused functions.

I think those should not be defined `static'.  If they are meant to
be called from within DDB, it's necessary to maintain a globally
unique function name anyway, so why having it `static'?

(Of course, the function remains in an `apparently unsued' state, but
for a non-static function, the compiler should be silent for this.)

-- 
cheers, J"org

joerg_wunsch@uriah.heep.sax.de -- http://www.sax.de/~joerg/ -- NIC: JW11-RIPE
Never trust an operating system you don't have sources for. ;-)

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-hackers" in the body of the message



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?19981206172744.53389>