Re: GCC nested functions?
From: Mitchell Blank Jr
Date: Wed May 12 2004 - 19:07:44 EST
Christoph Hellwig wrote:
> nested function are a horrible gcc misfeature.
True.
> So far people had enough
> taste to not introduce them without explicitly forbidding it ;-)
Almost true. Look at drivers/atm/horizon.c:make_rate(), which includes
a nested function called "set_cr()" There may be a couple other
examples in the drivers/atm directory, not sure.
The Intel CC guys made special mention of the ATM drivers when they
first started using their compiler for the kernel (icc supports most
gcc extensions, but apparently not nested functions) and they made special
mention of not being able to compile some ATM drivers because of this.
I'm not aware of nested functions anywhere else in the kernel though.
-Mitch
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/