GFlags: Fix usage of unused attribute
authorSergey Sharybin <sergey.vfx@gmail.com>
Thu, 22 Mar 2018 16:19:56 +0000 (17:19 +0100)
committerSergey Sharybin <sergey.vfx@gmail.com>
Thu, 22 Mar 2018 16:19:56 +0000 (17:19 +0100)
extern/gflags/README.blender
extern/gflags/src/gflags/gflags.h

index 1f6f011177667ac2e94fbfc6d9f0bf09ecf2dcc5..68dba11432932aea352705e657b3a4385d77f125 100644 (file)
@@ -21,3 +21,6 @@ Local modifications:
   not trigger strict compiler warning.
 
 - Did the same for CommandLineFlagParser::ValidateFlags().
+
+- Ifdef-ed __attribute((unused)) in gflags.h.
+  This file is compile-time configurable in upstream, so can not avoid change here.
index 02b40e158dc1cfb9bedffc2203c6c7bec55aeace..d5401f4f5757741b1b307df7c0fb9f23380532cd 100644 (file)
@@ -285,7 +285,11 @@ class GFLAGS_DLL_DECL FlagSaver {
 
   FlagSaver(const FlagSaver&);  // no copying!
   void operator=(const FlagSaver&);
-}__attribute((unused));
+}
+#ifdef __GNUC__
+__attribute((unused))
+#endif
+;
 
 // --------------------------------------------------------------------
 // Some deprecated or hopefully-soon-to-be-deprecated functions.