This is an archive of the discontinued LLVM Phabricator instance.

[libc++] Removes _LIBCPP_AVAILABILITY_TO_CHARS.
ClosedPublic

Authored by Mordante on May 16 2022, 10:38 PM.

Details

Reviewers
ldionne
Group Reviewers
Restricted Project
Commits
rGb968c3452b6a: [libc++] Removes _LIBCPP_AVAILABILITY_TO_CHARS.
Summary

After moving the std::to_chars base 10 implementation from the dylib to
the header the integral overloads of std::to_chars are available on all
platforms.

Remove the _LIBCPP_AVAILABILITY_TO_CHARS availability macro and update
the tests.

Depends on D125704

Diff Detail

Event Timeline

Mordante created this revision.May 16 2022, 10:38 PM
Herald added a project: Restricted Project. · View Herald TranscriptMay 16 2022, 10:38 PM
Mordante requested review of this revision.May 16 2022, 10:38 PM
Herald added a project: Restricted Project. · View Herald TranscriptMay 16 2022, 10:38 PM
Herald added a reviewer: Restricted Project. · View Herald Transcript
Mordante abandoned this revision.May 17 2022, 8:45 AM

Seems backdeployment fails so it seems we need to keep the availability macros.

Seems backdeployment fails so it seems we need to keep the availability macros.

It looks to me like the only failure is an XPASS in libcxx/test/std/utilities/charconv/charconv.from.chars/integral.roundtrip.pass.cpp, where you seem to have forgotten to remove the XFAIL line. I think this patch should be revived!

Mordante updated this revision to Diff 433121.May 31 2022, 10:05 AM

Applies @ldionne's suggestion to fix the CI.

Seems backdeployment fails so it seems we need to keep the availability macros.

It looks to me like the only failure is an XPASS in libcxx/test/std/utilities/charconv/charconv.from.chars/integral.roundtrip.pass.cpp, where you seem to have forgotten to remove the XFAIL line. I think this patch should be revived!

Thanks good catch!

ldionne accepted this revision.Jun 1 2022, 10:45 AM

LGTM.

Can we add a release note to mention that to_chars doesn't have a minimum deployment target anymore? It's something useful for folks to know.

libcxx/test/std/utilities/charconv/charconv.from.chars/integral.roundtrip.pass.cpp
12–13

This should be removed too!

This revision is now accepted and ready to land.Jun 1 2022, 10:45 AM
Mordante marked an inline comment as done.Jun 1 2022, 10:58 PM

LGTM.

Can we add a release note to mention that to_chars doesn't have a minimum deployment target anymore? It's something useful for folks to know.

Good point, I only wonder which section would be most appropriate "New features" or "ABI changes". WDYT?

LGTM.

Can we add a release note to mention that to_chars doesn't have a minimum deployment target anymore? It's something useful for folks to know.

Good point, I only wonder which section would be most appropriate "New features" or "ABI changes". WDYT?

I would say "New features" because from the user's perspective, it allows them to use this new feature even if they had back-deployment requirements before.

This revision was automatically updated to reflect the committed changes.
libcxx/include/charconv