Source-Changes archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: CVS commit: src/sys/kern



On Wed, Sep 06, 2006 at 08:01:25PM -0700, Garrett D'Amore wrote:
> >
> > Mark sizeof(tvp->tv_sec) check CONSTCOND.
> > No space between the sizeof and the paren.
...
> I still put space between sizeof and the paren out of habit -- its
> Solaris. (Apparently because sizeof is a language keyword rather than a
> function, it gets different spacing rules.)  Old habits die hard.

sizeof is actually an operator, not a function, so I always use either:
        sizeof variable
or:
        sizeof (type)

'sizeof(variable)' is almost as bad as 'return(value)'

        David

-- 
David Laight: david%l8s.co.uk@localhost



Home | Main Index | Thread Index | Old Index