This is an archive of the discontinued LLVM Phabricator instance.

Make _LIBCPP_DEPRECATED_ABI_DISABLE_PAIR_TRIVIAL_COPY_CTOR user-settable
AbandonedPublic

Authored by dim on Nov 30 2016, 11:57 AM.

Details

Summary

In rL275749 the old _LIBCPP_TRIVIAL_PAIR_COPY_CTOR define was replaced
by _LIBCPP_DEPRECATED_ABI_DISABLE_PAIR_TRIVIAL_COPY_CTOR, which is also
auto-detected.

However, it is not overridable by the user, since you cannot use -U or
#undef to get rid of the define after __config was included, at least
not without gross hacks.

In the FreeBSD ports tree we have at least one libc++ consumer that
really needs to turn on the trivial constructor (chromium), see
https://bugs.freebsd.org/214654 for the details. So I would like to
propose making _LIBCPP_DEPRECATED_ABI_DISABLE_PAIR_TRIVIAL_COPY_CTOR
user-settable (to either zero, or nonzero).

Event Timeline

dim updated this revision to Diff 79793.Nov 30 2016, 11:57 AM
dim retitled this revision from to Make _LIBCPP_DEPRECATED_ABI_DISABLE_PAIR_TRIVIAL_COPY_CTOR user-settable.
dim updated this object.
dim added reviewers: EricWF, emaste, mclow.lists, theraven.
dim added a subscriber: cfe-commits.
EricWF edited edge metadata.Dec 5 2016, 12:37 AM

@dim Do you still need this to fix the chromium bug?

dim abandoned this revision.Dec 5 2016, 1:25 AM

No, let's drop it. In the FreeBSD ports bug I have posted a patch to use _LIBCPP_ABI_UNSTABLE instead, which appears to work fine. And at some point we'll update to _LIBCPP_ABI_VERSION 2, but not today. :)