3137. Header for __cpp_lib_to_chars

Section: 17.3.1 [support.limits.general] Status: C++20 Submitter: S. B. Tam Opened: 2018-07-03 Last modified: 2022-08-23 10:16:04 UTC

Priority: 0

View all other issues in [support.limits.general].

View all issues with C++20 status.


After acceptance of P0941R2 into the working draft, in [support.limits.general], __cpp_lib_to_chars is required to be in <utility>. Since the relevant feature (std::to_chars and std::from_chars) is now in the header <charconv>, should the macro be defined in <charconv> instead of <utility>?

[Marshall provides P/R and context]

std::to_chars, etc were originally proposed for the header <utility> and SD-6 reflected that. Somewhere along the way, they was put into their own header <charconv>, but the document was never updated to reflect that.

When these macros were added to the standard, the (now incorrect) value was copied as well.

[2018-07-20 Status to Tentatively Ready after five positive votes on the reflector.]

[2018-11, Adopted in San Diego]

Proposed resolution:

This wording is relative to (the Rapperswil post-mailing standard).

Change 17.3.1 [support.limits.general] (Table 35) as indicated:

Macro nameValueHeader(s)