Some tests repeat the definition of DELETE_FUNCTION macro locally.
However, it's not even requred to guard against in the C++03 case since
Clang supports = delete; in C++03 mode. A warning is issued but
libc++ tests run with -Wno-c++11-extensions, so this isn't an issue.
Since we don't support other compilers in C++03 mode, = delete; is
always available for use. As such, inline all calls of DELETE_FUNCTION
to use = delete;.
Details
Details
- Reviewers
ldionne • Quuxplusone Mordante - Group Reviewers
Restricted Project - Commits
- rG8cf5319affc2: [libc++][test] Use = delete over DELETE_FUNCTION. NFC.
Diff Detail
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
Comment Actions
LGTM, but, have you tried just inlining = delete; in all these places? I believe Clang supports it in C++03 mode, and we don't care about other compilers in C++03 mode.
Comment Actions
Just tried inlining = delete; everywhere. We'll see if BuildKite is happy! It seems you're right that Clang supports it in C++03 mode. A warning is issued, but the libc++ tests run with -Wno-c++11-extensions, so we should be OK. Small example at https://godbolt.org/z/KvYKMqWfz