This is an archive of the discontinued LLVM Phabricator instance.

[clang] Add test for C++ DR2390
ClosedPublic

Authored by tbaeder on Feb 8 2022, 4:07 AM.

Details

Summary

DR2390 clarifies that the argument to __has_cpp_attribute() needs to be
macro-expanded. Clang already supports this and tests it explicitly in
clang/test/Preprocessor/has_attribute.cpp.

Copy the test over to clang/test/CXX/drs/ so the make_cxx_drs script
picks it up.

Diff Detail

Event Timeline

tbaeder requested review of this revision.Feb 8 2022, 4:07 AM
tbaeder created this revision.
Herald added a project: Restricted Project. · View Herald TranscriptFeb 8 2022, 4:07 AM
Herald added a subscriber: cfe-commits. · View Herald Transcript
aaron.ballman accepted this revision.Feb 8 2022, 4:19 AM

LGTM, thank you for this!

This revision is now accepted and ready to land.Feb 8 2022, 4:19 AM
This revision was automatically updated to reflect the committed changes.