17.2.34 Warn_unused_result Function Attribute

The warn_unused_result attribute instructs the compiler to warn if the return value of the indicated function is unused by a caller, for example:
void __attribute__ ((warn_unused_result)) foo(void);