mirror of
https://github.com/libsdl-org/SDL.git
synced 2025-05-15 01:08:26 +00:00
include: Move SDL_HAS_BUILTIN to SDL_begin_code.h, document it.
This macro fits better here, since most of the other macros in this file are for testing similar compiler/target features, etc.
This commit is contained in:
parent
e46d8756e5
commit
ff366fba87
2 changed files with 22 additions and 12 deletions
|
@ -147,17 +147,6 @@ void *alloca(size_t);
|
|||
typedef int SDL_compile_time_assert_ ## name[(x) * 2 - 1]
|
||||
#endif
|
||||
|
||||
/**
|
||||
* Check if the compiler supports a given builtin.
|
||||
* Supported by virtually all clang versions and recent gcc. Use this
|
||||
* instead of checking the clang version if possible.
|
||||
*/
|
||||
#ifdef __has_builtin
|
||||
#define SDL_HAS_BUILTIN(x) __has_builtin(x)
|
||||
#else
|
||||
#define SDL_HAS_BUILTIN(x) 0
|
||||
#endif
|
||||
|
||||
/**
|
||||
* The number of elements in a static array.
|
||||
*
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue