Added NazaraStringify(Macro)
Former-commit-id: 1b4b3165153013e9d2ff5e78c54c4a214deb7ac4
This commit is contained in:
parent
a33960c2aa
commit
c934d8ed6b
|
|
@ -35,6 +35,7 @@
|
||||||
|
|
||||||
#include <Nazara/Core/Config.hpp>
|
#include <Nazara/Core/Config.hpp>
|
||||||
|
|
||||||
|
// Identification du compilateur
|
||||||
///TODO: Rajouter des tests d'identification de compilateurs
|
///TODO: Rajouter des tests d'identification de compilateurs
|
||||||
#if defined(__BORLANDC__)
|
#if defined(__BORLANDC__)
|
||||||
#define NAZARA_COMPILER_BORDLAND
|
#define NAZARA_COMPILER_BORDLAND
|
||||||
|
|
@ -70,8 +71,7 @@
|
||||||
#error This compiler is not fully supported
|
#error This compiler is not fully supported
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#define NazaraUnused(a) (void) a
|
// Identification de la plateforme
|
||||||
|
|
||||||
#if defined(_WIN32)
|
#if defined(_WIN32)
|
||||||
#define NAZARA_PLATFORM_WINDOWS
|
#define NAZARA_PLATFORM_WINDOWS
|
||||||
|
|
||||||
|
|
@ -133,15 +133,22 @@
|
||||||
#define NAZARA_API
|
#define NAZARA_API
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
// Détection 64 bits
|
||||||
#if !defined(NAZARA_PLATFORM_x64) && (defined(_WIN64) || defined(__amd64__) || defined(__x86_64__) || defined(__ia64__) || defined(__ia64) || \
|
#if !defined(NAZARA_PLATFORM_x64) && (defined(_WIN64) || defined(__amd64__) || defined(__x86_64__) || defined(__ia64__) || defined(__ia64) || \
|
||||||
defined(_M_IA64) || defined(__itanium__) || defined(__MINGW64__))
|
defined(_M_IA64) || defined(__itanium__) || defined(__MINGW64__))
|
||||||
#define NAZARA_PLATFORM_x64
|
#define NAZARA_PLATFORM_x64
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
// Définit NDEBUG si NAZARA_DEBUG n'est pas présent
|
||||||
#if !defined(NAZARA_DEBUG) && !defined(NDEBUG)
|
#if !defined(NAZARA_DEBUG) && !defined(NDEBUG)
|
||||||
#define NDEBUG
|
#define NDEBUG
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
// Macros supplémentaires
|
||||||
|
#define NazaraStringifyMacro(s) NazaraStringify(s) // http://gcc.gnu.org/onlinedocs/cpp/Stringification.html#Stringification
|
||||||
|
#define NazaraStringify(s) #s
|
||||||
|
#define NazaraUnused(a) (void) a
|
||||||
|
|
||||||
#include <cstdint>
|
#include <cstdint>
|
||||||
|
|
||||||
static_assert(sizeof(int8_t) == 1, "int8_t is not of the correct size" );
|
static_assert(sizeof(int8_t) == 1, "int8_t is not of the correct size" );
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue