macros: Add a generic way to get and check the supported C standard

Try to get the value of __STDC_VERSION__ if supported, if not just
fallback to the oldest standard that any compiler should handle.
This commit is contained in:
Marco Trevisan (Treviño)
2022-09-14 04:16:56 +02:00
parent 14ba699508
commit 633561ada2
6 changed files with 152 additions and 2 deletions

View File

@@ -411,6 +411,8 @@ G_GNUC_INTERNAL
G_GNUC_MAY_ALIAS
<SUBSECTION>
G_C_STD_VERSION
G_C_STD_CHECK_VERSION
G_CXX_STD_VERSION
G_CXX_STD_CHECK_VERSION