Graphviz 13.0.0~dev.20241220.2304
Loading...
Searching...
No Matches
unused.h File Reference

abstraction for squashing compiler warnings for unused symbols More...

This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define UNUSED   /* nothing */
 
#define WUR   /* nothing */
 

Macro Definition Documentation

◆ UNUSED

#define UNUSED   /* nothing */

squash an unused variable/function warning in C

e.g.

static UNUSED void my_uncalled_function(void) { } static UNUSED int my_unused_variable;

Use this sparingly, as the MSVC version applies to everything in both the current and next line, so can end up accidentally masking genuine problems.

Definition at line 25 of file unused.h.

◆ WUR

#define WUR   /* nothing */

annotate that a function’s return value should not be ignored

e.g.

WUR int foo(void) { return 42; } void bar(void) { foo(); // ← this line will generate a compiler warning }

Definition at line 43 of file unused.h.