This is an archive of the discontinued LLVM Phabricator instance.

[libcxx] [test] Make futures.overview/future_errc.pass.cpp and launch.pass.cpp more portable.
ClosedPublic

Authored by STL_MSFT on Jun 29 2016, 4:44 PM.

Details

Summary

Make futures.overview/future_errc.pass.cpp and launch.pass.cpp more portable.

future_errc.pass.cpp was assuming specific values, which aren't guaranteed by the Standard, and MSVC uses different ones. Update the comment, and rewrite the tests to verify the Standard's guarantees of distinctness and nonzeroness.

launch.pass.cpp also contains non-Standard assumptions. They happen to be true for MSVC, with the exception of a static_assert about bitwise NOT. Apparently for libcxx, this operator modifies only 2 bits. For MSVC, it modifies all the bits in the representation. Mark this static_assert as libcxx-specific.

Diff Detail

Event Timeline

STL_MSFT updated this revision to Diff 62311.Jun 29 2016, 4:44 PM
STL_MSFT retitled this revision from to [libcxx] [test] Make futures.overview/future_errc.pass.cpp and launch.pass.cpp more portable..
STL_MSFT updated this object.
STL_MSFT added reviewers: EricWF, mclow.lists.
STL_MSFT added a subscriber: cfe-commits.
EricWF accepted this revision.Jun 29 2016, 10:06 PM
EricWF edited edge metadata.
This revision is now accepted and ready to land.Jun 29 2016, 10:06 PM
EricWF closed this revision.Jun 29 2016, 10:07 PM

r274211.