This is an archive of the discontinued LLVM Phabricator instance.

[libcxx] [test] Mark bits of fs.enum tests as libcpp specific
ClosedPublic

Authored by mstorsjo on Oct 21 2020, 3:49 AM.

Details

Summary

The individual enum values in copy_options and file_type aren't specified in the standard.

The standard doesn't require fs::path::format to be a scoped enum.

Diff Detail

Event Timeline

mstorsjo created this revision.Oct 21 2020, 3:49 AM
Herald added a project: Restricted Project. · View Herald TranscriptOct 21 2020, 3:49 AM
Herald added 1 blocking reviewer(s): Restricted Project. · View Herald Transcript
mstorsjo requested review of this revision.Oct 21 2020, 3:49 AM
ldionne accepted this revision.Oct 21 2020, 5:32 AM
ldionne added a subscriber: ldionne.

LGTM with suggested changes.

libcxx/test/std/input.output/filesystems/fs.enum/enum.copy_options.pass.cpp
39

Please use LIBCPP_STATIC_ASSERT instead (it is defined in test_macros.h. I'd like to avoid using macros defined in individual stdlibs in the test suite as much as possible.

Also, it would make sense to add a short comment explaining why those are libc++ specific.

This revision is now accepted and ready to land.Oct 21 2020, 5:32 AM
mstorsjo updated this revision to Diff 299647.Oct 21 2020, 5:38 AM

Using LIBCPP_STATIC_ASSERT in the changed lines, and added some comments. There's a few cases of existing LIBCPP_ONLY(static_assert()) in other lines nearby that I'm not touching here though.

ldionne accepted this revision.Oct 21 2020, 5:57 AM