diff options
author | Ramsay Jones <ramsay@ramsay1.demon.co.uk> | 2010-01-11 22:51:42 +0000 |
---|---|---|
committer | Ramsay Jones <ramsay@ramsay1.demon.co.uk> | 2010-01-20 20:19:55 +0000 |
commit | 1a7bae4d0f9d9314b905109b5b321219b7e6be3b (patch) | |
tree | 81723c22eae0570f3774ac588b572636f34a7467 /src/cc-compat.h | |
parent | e3fe32b6a4ecb340fa7c9802285711cc52b8a101 (diff) | |
download | libgit2-1a7bae4d0f9d9314b905109b5b321219b7e6be3b.tar.gz |
Fix some "unused parameter" warnings with -Wextra
Signed-off-by: Ramsay Jones <ramsay@ramsay1.demon.co.uk>
Diffstat (limited to 'src/cc-compat.h')
-rw-r--r-- | src/cc-compat.h | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/src/cc-compat.h b/src/cc-compat.h index 488de7f11..aefe66d19 100644 --- a/src/cc-compat.h +++ b/src/cc-compat.h @@ -30,6 +30,16 @@ # define GIT_TYPEOF(x) #endif +#ifdef __cplusplus +# define GIT_UNUSED(x) +#else +# ifdef __GNUC__ +# define GIT_UNUSED(x) x __attribute__ ((__unused__)) +# else +# define GIT_UNUSED(x) x +# endif +#endif + /* * Does our compiler/platform support the C99 <inttypes.h> and * <stdint.h> header files. (C99 requires that <inttypes.h> |