From c9a6483edf3aacc011b6562658096cd8fd94415b Mon Sep 17 00:00:00 2001 From: Jamie Reece Wilson Date: Thu, 21 Dec 2023 13:51:55 +0000 Subject: [PATCH] [+] C++23 detection [+] Other missing languages --- AuroraEnvironment.h | 9 +++++++++ AuroraEnvironment.hpp | 22 +++++++++++++++++++--- 2 files changed, 28 insertions(+), 3 deletions(-) diff --git a/AuroraEnvironment.h b/AuroraEnvironment.h index 7035f2e..336502b 100644 --- a/AuroraEnvironment.h +++ b/AuroraEnvironment.h @@ -145,6 +145,15 @@ #elif defined(_AURORA_DONT_QUESTION_ME_14) #define AU_LANG_CPP_14 #define AU_LANG_CPP + #elif defined(_AURORA_DONT_QUESTION_ME_20) + #define AU_LANG_CPP_20 + #define AU_LANG_CPP + #elif defined(_AURORA_DONT_QUESTION_ME_23) + #define AU_LANG_CPP_23 + #define AU_LANG_CPP + #elif __cplusplus > 202002L + #define AU_LANG_CPP_23 + #define AU_LANG_CPP #elif __cplusplus > 201703L #define AU_LANG_CPP_20 #define AU_LANG_CPP diff --git a/AuroraEnvironment.hpp b/AuroraEnvironment.hpp index f0c0bf0..d8d3b70 100644 --- a/AuroraEnvironment.hpp +++ b/AuroraEnvironment.hpp @@ -266,11 +266,27 @@ namespace Aurora::Build eJavaScript, eKotlin, eHLSL, - gGLSL, - eCpp20Plus = 20 + eGLSL, + eTypeScript, + eLua, + ePython, + eIM_START = 15, + eIM_SPIR_V = 15, + eIM_MISL = 16, + eIM_JVM = 17, + eIM_V8 = 18, + eIM_USER_CUSTOM = 19, + eIM_END = 20, + // - + // cpp21 does not exist + // cpp22 does not exist + eCpp23 = 23 + // ... }; - #if defined (AU_LANG_CPP_20) + #if defined(AU_LANG_CPP_23) + static const ELanguage kCurrentLanguage = ELanguage::eCpp23; + #elif defined (AU_LANG_CPP_20) static const ELanguage kCurrentLanguage = ELanguage::eCpp20; #elif defined (AU_LANG_CPP_17) static const ELanguage kCurrentLanguage = ELanguage::eCpp17;