Date: Thu, 28 Jan 1999 01:15:54 -0800 (PST) From: Matthew Dillon <dillon@apollo.backplane.com> To: Julian Elischer <julian@whistle.com> Cc: current@FreeBSD.ORG Subject: Re: -Wall -Wcast-qual and SYSINIT Message-ID: <199901280915.BAA02632@apollo.backplane.com> References: <Pine.BSF.4.05.9901280034480.304-100000@s204m82.isp.whistle.com>
next in thread | previous in thread | raw e-mail | index | archive | help
:On Thu, 28 Jan 1999, Matthew Dillon wrote: : :OK I understand now.. :theoretically I guess you should have two types of SYSINIT, :however you are already not able to check the TYPE of the argument due to :it being passed through the void form, so losing the 'const'-ness is not :that much of a loss. The pragmetic answer may just be to 'cast' in the :macro. I'd kinda like to keep the const-ness because I can see device drivers putting static structures in const ( i.e. read-only TEXT ) space and would like to have the safety factor of knowing that they aren't actually modified - not just not modified by the initialization routine, but also not modified later on in the device driver code. But I also want to eventually quiet the warning -- I agree that for SYSINIT's, loosing const is not a huge issue. Quieting the warning without fixing the problem with -Wcast-qual enabled is not pretty, though. I think -Wcast-qual is pretty important if we intend to fix the volatile conversion mess. -Matt Matthew Dillon <dillon@backplane.com> To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199901280915.BAA02632>