From 85c7f15a1b0d25d9d855ef771fa753b2361b277a Mon Sep 17 00:00:00 2001 From: Max Kellermann Date: Fri, 10 Mar 2017 21:32:54 +0100 Subject: [PATCH] Compiler.h: add macro GCC_MAKE_VERSION() --- src/Compiler.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/Compiler.h b/src/Compiler.h index 9756e1f..43bc9a8 100644 --- a/src/Compiler.h +++ b/src/Compiler.h @@ -24,12 +24,12 @@ (defined(__GNUC__) && \ (__GNUC__ > (major) || (__GNUC__ == (major) && __GNUC_MINOR__ >= (minor)))) +#define GCC_MAKE_VERSION(major, minor, patchlevel) ((major) * 10000 + (minor) * 100 + patchlevel) + #ifdef __GNUC__ -#define GCC_VERSION (__GNUC__ * 10000 \ - + __GNUC_MINOR__ * 100 \ - + __GNUC_PATCHLEVEL__) +# define GCC_VERSION GCC_MAKE_VERSION(__GNUC__, __GNUC_MINOR__, __GNUC_PATCHLEVEL__) #else -#define GCC_VERSION 0 +# define GCC_VERSION 0 #endif #if GCC_CHECK_VERSION(4,0) -- 2.30.2