This is an archive of the discontinued LLVM Phabricator instance.

[libc++] Remove MSVC tests checked into the libc++ test suite
ClosedPublic

Authored by ldionne on Sep 27 2022, 2:59 PM.

Details

Summary

We should strive to have our own tests, except when there is overwhelming
value in using another standard library's existing tests. The reason is
that it ensures that implementations don't all start relying on the same
interpretation of the Standard.

The unique_ptr tests did not add any test coverage AFAICT, and the
forward_like tests were moved to the style used everywhere in the
libc++ test suite.

Note that I got to this because this actually broke a downstream
configuration where we use -ffreestanding. The signature of main()
was not consistent with the signature we (need to) use everywhere
in the test suite.

Diff Detail

Event Timeline

ldionne created this revision.Sep 27 2022, 2:59 PM
Herald added a project: Restricted Project. · View Herald TranscriptSep 27 2022, 2:59 PM
ldionne requested review of this revision.Sep 27 2022, 2:59 PM
Herald added a project: Restricted Project. · View Herald TranscriptSep 27 2022, 2:59 PM
Herald added a reviewer: Restricted Project. · View Herald Transcript
philnik accepted this revision as: philnik.Sep 27 2022, 3:05 PM
philnik added a reviewer: Mordante.
philnik added a subscriber: philnik.

I'm fine with this, but we might want to look into running tests from other standard libraries on libc++ to find implementation divergence and potentially have some extra test coverage.

I'm fine with this, but we might want to look into running tests from other standard libraries on libc++ to find implementation divergence and potentially have some extra test coverage.

Yes, I 100% agree. It would be great to have e.g. a CI job that runs the MSVC tests using libc++. I just don't think these tests should be checked into our own tree.

ldionne accepted this revision.Sep 28 2022, 5:02 AM
This revision is now accepted and ready to land.Sep 28 2022, 5:02 AM
This revision was landed with ongoing or failed builds.Sep 28 2022, 5:03 AM
This revision was automatically updated to reflect the committed changes.

I'm fine with this, but we might want to look into running tests from other standard libraries on libc++ to find implementation divergence and potentially have some extra test coverage.

Yes, I 100% agree. It would be great to have e.g. a CI job that runs the MSVC tests using libc++. I just don't think these tests should be checked into our own tree.

As discussed on Discord I think they need to be checked in. But We should look at that when we really start to use this feature. No objection to remove this test.

libcxx/test/std/utilities/utility/forward/forward_like.pass.cpp