Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 10 Jul 2008 09:45:56 -0600 (MDT)
From:      "M. Warner Losh" <imp@bsdimp.com>
To:        das@freebsd.org
Cc:        cvs-src@freebsd.org, danger@freebsd.org, src-committers@freebsd.org, cvs-all@freebsd.org
Subject:   Re: cvs commit: src/share/man/man9 style.9
Message-ID:  <20080710.094556.-262765509.imp@bsdimp.com>
In-Reply-To: <20080709154945.GA47824@zim.MIT.EDU>
References:  <200807091404.m69E4jiC075715@repoman.freebsd.org> <20080709154945.GA47824@zim.MIT.EDU>

next in thread | previous in thread | raw e-mail | index | archive | help
In message: <20080709154945.GA47824@zim.MIT.EDU>
            David Schultz <das@FreeBSD.org> writes:
: On Wed, Jul 09, 2008, Daniel Gerzo wrote:
: > -Do not declare functions inside other functions; ANSI C says that
: > -such declarations have file scope regardless of the nesting of the
: > -declaration.
: > -Hiding file declarations in what appears to be a local
: > -scope is undesirable and will elicit complaints from a good compiler.
: > +Do not declare functions inside other functions; nested functions are
: > +a GCC extension and are not permitted by ANSI C.
: 
: We use lots of extensions that aren't strict ANSI C. I think the
: real reason not to use them is that gcc's nested functions are
: particularly unwieldily. First, they're not true lexical closures
: (and can't be), which makes them much less useful. Second, they
: are unsupported unless a number of assumptions are met, e.g., must
: have an executable stack, must be able to invalidate the I cache
: from userland, and must not have separate I and D address spaces.
: Nested functions abominable enough that Apple disabled the feature
: in OS X's build of gcc --- and the Sun and Intel compilers don't
: support them, even though Intel claims nearly complete gcc
: compatibility.

I think the bug in the commit was the '-' lines.  The '+' lines were
good.  Maybe a .Pp line would then be needed.

Warner



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