Re: [PATCH] SPI: improve sysfs compiler complaint handling

From: David Brownell
Date: Thu Oct 12 2006 - 14:09:29 EST


On Wednesday 11 October 2006 6:49 pm, Jeff Garzik wrote:

> The compiler complains, even with the "(void)".

> - (void) device_for_each_child(master->cdev.dev, NULL, __unregister);

Sure seems like a compiler bug to me. For over two decades, casting
a value into the void has been a standard idiom for saying "ignore
that value" ... ISTR using it to get rid of "unused value" warnings
with LINT on BSD 4.1 systems.

Does anyone know why the GCC folk have decided to go against decades
of common practice here???

- Dave

-
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/