diff options
author | Gregory Nutt <gnutt@nuttx.org> | 2014-03-30 07:58:58 -0600 |
---|---|---|
committer | Gregory Nutt <gnutt@nuttx.org> | 2014-03-30 07:58:58 -0600 |
commit | a787b302db9dd3c2dc9beb609eefc93ec8ae25c1 (patch) | |
tree | 327ea4d6ad94c3ac8a41cd81044b1f186d969b20 /nuttx/include/nuttx/compiler.h | |
parent | b70dfa42592a9e8bd552975f5474248109acb44d (diff) | |
download | nuttx-a787b302db9dd3c2dc9beb609eefc93ec8ae25c1.tar.gz nuttx-a787b302db9dd3c2dc9beb609eefc93ec8ae25c1.tar.bz2 nuttx-a787b302db9dd3c2dc9beb609eefc93ec8ae25c1.zip |
Add macro UNUSED to eliminate warnings about variables that are set to unused values
Diffstat (limited to 'nuttx/include/nuttx/compiler.h')
-rw-r--r-- | nuttx/include/nuttx/compiler.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/nuttx/include/nuttx/compiler.h b/nuttx/include/nuttx/compiler.h index 1e6acd6ff..8ed7e4ac5 100644 --- a/nuttx/include/nuttx/compiler.h +++ b/nuttx/include/nuttx/compiler.h @@ -58,6 +58,10 @@ # define CONFIG_HAVE_FUNCTIONNAME 1 /* Has __FUNCTION__ */ # define CONFIG_HAVE_FILENAME 1 /* Has __FILE__ */ +/* Indicate that a local variable is not used */ + +# define UNUSED(a) ((void)(a)) + /* Attributes * * GCC supports weak symbols which can be used to reduce code size because |