[glib/nacho/gmacros-glib-2-68] gmacros: missing check if __STDC_VERSION__ is defined
- From: Ignacio Casal Quinteiro <icq src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [glib/nacho/gmacros-glib-2-68] gmacros: missing check if __STDC_VERSION__ is defined
- Date: Tue, 27 Apr 2021 10:23:53 +0000 (UTC)
commit 9584f3a4caa3e82981259d2f70d1e3d556e080a1
Author: Ignacio Casal Quinteiro <qignacio amazon com>
Date: Tue Apr 27 12:21:07 2021 +0200
gmacros: missing check if __STDC_VERSION__ is defined
This fixes warnings when compiling on old distros like centos 7
glib/gmacros.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
---
diff --git a/glib/gmacros.h b/glib/gmacros.h
index 4c571083b..f7e797f0d 100644
--- a/glib/gmacros.h
+++ b/glib/gmacros.h
@@ -967,7 +967,7 @@
#elif (defined (__cplusplus) && __cplusplus >= 201103 && !(__GNUC__ == 4 && __GNUC_MINOR__ == 7)) || defined
(_MSC_VER) && (_MSC_VER >= 1900)
# define G_NORETURN [[noreturn]]
/* Use ISO C11 syntax when the compiler supports it. */
-#elif __STDC_VERSION__ >= 201112 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 7)
+#elif defined (__STDC_VERSION__) && __STDC_VERSION__ >= 201112 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 7)
# define G_NORETURN _Noreturn
#else
# define G_NORETURN /* empty */
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]