|
@@ -28,10 +28,10 @@
|
|
|
*/
|
|
|
|
|
|
/* This shouldn't be nested -- included it around code only. */
|
|
|
-#ifdef _begin_code_h
|
|
|
+#ifdef SDL_begin_code_h
|
|
|
#error Nested inclusion of begin_code.h
|
|
|
#endif
|
|
|
-#define _begin_code_h
|
|
|
+#define SDL_begin_code_h
|
|
|
|
|
|
#ifndef SDL_DEPRECATED
|
|
|
# if defined(__GNUC__) && (__GNUC__ >= 4) /* technically, this arrived in gcc 3.1, but oh well. */
|
|
@@ -171,17 +171,17 @@
|
|
|
#define SDL_FALLTHROUGH [[fallthrough]]
|
|
|
#else
|
|
|
#if defined(__has_attribute)
|
|
|
-#define _HAS_FALLTHROUGH __has_attribute(__fallthrough__)
|
|
|
+#define SDL_HAS_FALLTHROUGH __has_attribute(__fallthrough__)
|
|
|
#else
|
|
|
-#define _HAS_FALLTHROUGH 0
|
|
|
+#define SDL_HAS_FALLTHROUGH 0
|
|
|
#endif /* __has_attribute */
|
|
|
-#if _HAS_FALLTHROUGH && \
|
|
|
+#if SDL_HAS_FALLTHROUGH && \
|
|
|
((defined(__GNUC__) && __GNUC__ >= 7) || \
|
|
|
(defined(__clang_major__) && __clang_major__ >= 10))
|
|
|
#define SDL_FALLTHROUGH __attribute__((__fallthrough__))
|
|
|
#else
|
|
|
#define SDL_FALLTHROUGH do {} while (0) /* fallthrough */
|
|
|
-#endif /* _HAS_FALLTHROUGH */
|
|
|
-#undef _HAS_FALLTHROUGH
|
|
|
+#endif /* SDL_HAS_FALLTHROUGH */
|
|
|
+#undef SDL_HAS_FALLTHROUGH
|
|
|
#endif /* C++17 or C2x */
|
|
|
#endif /* SDL_FALLTHROUGH not defined */
|