Issue 1111: Inconsistent definitions of version macros

Authors: Jay Ghiron
Date: 2026-09-17
Submitted against: C23
Status: Open

Consider the following two macros:

The macro

__STDC_VERSION_ASSERT_H__

is an integer constant expression with a value equivalent to 202311L.

(C23 7.2.1 "General" paragraph 4.)

The feature test macro __STDC_VERSION_FENV_H__ expands to the token 202311L.

(C23 7.6.1 "General" paragraph 5.)

These two macros are specified differently, the former requiring a particular value while the latter requires an exact sequence of tokens. Is there any reason to specify these differently? Outside of preprocessing, the only observable difference is that the type of the former might not be long. The following are all macros specified with an exact sequence of tokens of the form yyyymmL:

The following are all macros specified to be integer constant expressions with the same value as an integer constant of the form yyyymmL:

C2Y also adds __STDC_VERSION_STDCOUNTOF_H__ and __STDC_VERSION_STDMCHAR_H__ which are defined by value rather than a specific sequence of tokens.