Skip to content
Permalink
Browse files

Fix android build with osgeo4a

  • Loading branch information
elpaso committed Mar 26, 2018
1 parent 10044fb commit ecfbe8a141dbe72751ee234bec13397aeb79e796
Showing with 10 additions and 4 deletions.
  1. +10 −4 src/core/qgis.h
@@ -555,25 +555,31 @@ typedef unsigned long long qgssize;
#define NODISCARD [[nodiscard]]
#elif defined(_MSC_VER)
#define NODISCARD // no support
#elif __has_cpp_attribute(nodiscard)
#define NODISCARD [[nodiscard]]
#elif __has_cpp_attribute(gnu::warn_unused_result)
#elif defined(__has_cpp_attribute)
#if __has_cpp_attribute(gnu::warn_unused_result)
#define NODISCARD [[gnu::warn_unused_result]]
#else
#define NODISCARD Q_REQUIRED_RESULT
#endif
#else
#define NODISCARD Q_REQUIRED_RESULT
#endif

#if __cplusplus >= 201703L
#define MAYBE_UNUSED [[maybe_unused]]
#elif defined(__clang__)
#define MAYBE_UNUSED [[maybe_unused]]
#elif defined(_MSC_VER)
#define MAYBE_UNUSED // no support
#elif __has_cpp_attribute(gnu::unused)
#elif defined(__has_cpp_attribute)
#if __has_cpp_attribute(gnu::unused)
#define MAYBE_UNUSED [[gnu::unused]]
#else
#define MAYBE_UNUSED
#endif
#else
#define MAYBE_UNUSED
#endif



0 comments on commit ecfbe8a

Please sign in to comment.
You can’t perform that action at this time.