Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Fix android build with osgeo4a
  • Loading branch information
elpaso committed Mar 27, 2018
1 parent 10044fb commit ecfbe8a
Showing 1 changed file with 10 additions and 4 deletions.
14 changes: 10 additions & 4 deletions src/core/qgis.h
Expand Up @@ -555,25 +555,31 @@ typedef unsigned long long qgssize;
#define NODISCARD [[nodiscard]] #define NODISCARD [[nodiscard]]
#elif defined(_MSC_VER) #elif defined(_MSC_VER)
#define NODISCARD // no support #define NODISCARD // no support
#elif __has_cpp_attribute(nodiscard) #elif defined(__has_cpp_attribute)
#define NODISCARD [[nodiscard]] #if __has_cpp_attribute(gnu::warn_unused_result)
#elif __has_cpp_attribute(gnu::warn_unused_result)
#define NODISCARD [[gnu::warn_unused_result]] #define NODISCARD [[gnu::warn_unused_result]]
#else #else
#define NODISCARD Q_REQUIRED_RESULT #define NODISCARD Q_REQUIRED_RESULT
#endif #endif
#else
#define NODISCARD Q_REQUIRED_RESULT
#endif


#if __cplusplus >= 201703L #if __cplusplus >= 201703L
#define MAYBE_UNUSED [[maybe_unused]] #define MAYBE_UNUSED [[maybe_unused]]
#elif defined(__clang__) #elif defined(__clang__)
#define MAYBE_UNUSED [[maybe_unused]] #define MAYBE_UNUSED [[maybe_unused]]
#elif defined(_MSC_VER) #elif defined(_MSC_VER)
#define MAYBE_UNUSED // no support #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]] #define MAYBE_UNUSED [[gnu::unused]]
#else #else
#define MAYBE_UNUSED #define MAYBE_UNUSED
#endif #endif
#else
#define MAYBE_UNUSED
#endif






Expand Down

0 comments on commit ecfbe8a

Please sign in to comment.