Subject: Re: Style guide
To: Mike Long <mikel@shore.net>
From: Chris G. Demetriou <cgd@pa.dec.com>
List: current-users
Date: 05/28/1997 09:06:17
> >Oh, just to add more fuel to the fire, I also have a problem with the
> >use of (void) in front of every function call that discards it's return
> >value. Does anyone have a good arguemnt for keeping this? It really
> >bloats code for no reason IMO.
>
> I find (void) to be a useful stylistic convention. What
>
> (void) syscall(...);
>
> says to me is "yes, I know that this syscall can return an error but I
> wish to plow on regardless." It indicates that the author intended to
> discard the return value, as opposed to simply being sloppy and
> forgetting to check the value returned by the syscall.
>
> Note that it only 'bloats' the source; object code is unaffected.
It's not just a stylistic convention. It's actually useful. Think
'lint'.
cgd