Controls the issuing of warning messages when function results are ignored.
#pragma warn_resultnotused on | off | reset
If you enable this pragma, the compiler issues a warning message when it encounters a statement that calls a function without using its result. To prevent this, cast the statement with (void) . Example of Function Calls with Unused Results provides an example.
#pragma warn_resultnotused on
extern int bar();
void func()
{
bar(); /* WARNING: result of function call is not used. */
void(bar()); /* OK: void cast suppresses warning. */
}
This pragma does not correspond to any panel setting. By default, this pragma is off.