From: Joel Rosdahl Date: Thu, 9 Aug 2012 13:09:16 +0000 (+0200) Subject: Rename static_assert macro to avoid clash with any preexisting static_assert X-Git-Tag: v3.1.8~3 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=0010ba1ac6071a5585b8a59df896855b1d711974;p=thirdparty%2Fccache.git Rename static_assert macro to avoid clash with any preexisting static_assert --- diff --git a/manifest.c b/manifest.c index 335874b78..7f02ede0c 100644 --- a/manifest.c +++ b/manifest.c @@ -66,7 +66,8 @@ static const uint32_t MAGIC = 0x63436d46U; static const uint8_t VERSION = 0; static const uint32_t MAX_MANIFEST_ENTRIES = 100; -#define static_assert(e) do { enum { static_assert__ = 1/(e) }; } while (0) +#define ccache_static_assert(e) \ + do { enum { ccache_static_assert__ = 1/(e) }; } while (0) struct file_info { /* Index to n_files. */ @@ -106,7 +107,7 @@ struct manifest { static unsigned int hash_from_file_info(void *key) { - static_assert(sizeof(struct file_info) == 24); /* No padding. */ + ccache_static_assert(sizeof(struct file_info) == 24); /* No padding. */ return murmurhashneutral2(key, sizeof(struct file_info), 0); }