From 93ac3e19f06c31535f50a1aa04c31fb6d0326261 Mon Sep 17 00:00:00 2001 From: Deomid Ryabkov <rojer@cesanta.com> Date: Tue, 3 Jul 2018 17:23:22 +0300 Subject: [PATCH] Stringify multi-word macros correctly Use vararg macros for this. PUBLISHED_FROM=735c40b79dedef17a1fdbb5b846e984df0ae7018 --- mongoose.h | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/mongoose.h b/mongoose.h index 4550c4819..5eeaee66e 100644 --- a/mongoose.h +++ b/mongoose.h @@ -2500,7 +2500,11 @@ int cs_base64_decode(const unsigned char *s, int len, char *dst, int *dec_len); * Expands to a string representation of its argument: e.g. * `CS_STRINGIFY_LIT(5) expands to "5"` */ +#if !defined(_MSC_VER) || _MSC_VER >= 1900 +#define CS_STRINGIFY_LIT(...) #__VA_ARGS__ +#else #define CS_STRINGIFY_LIT(x) #x +#endif /* * Expands to a string representation of its argument, which is allowed -- GitLab