[PATCH] D133354: [Clang]: Diagnose deprecated copy operations also in MSVC compatibility mode

Julius via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Fri Sep 9 12:48:37 PDT 2022


ningvin added a comment.

That is indeed a better option than to simply copy the test case. I did some more digging and found the following test cases which reference the deprecated copy warning (all located under clang/test/CXX/):

- deprecated.cpp <https://github.com/llvm/llvm-project/blob/main/clang/test/SemaCXX/deprecated.cpp>
- deprecated-copy.cpp <https://github.com/llvm/llvm-project/blob/main/clang/test/SemaCXX/deprecated-copy.cpp>
- deprecated-copy-with-dtor.cpp <https://github.com/llvm/llvm-project/blob/main/clang/test/SemaCXX/deprecated-copy-with-dtor.cpp>
- deprecated-copy-with-user-provided-copy.cpp <https://github.com/llvm/llvm-project/blob/main/clang/test/SemaCXX/deprecated-copy-with-user-provided-copy.cpp>
- deprecated-copy-with-user-provided-dtor.cpp <https://github.com/llvm/llvm-project/blob/main/clang/test/SemaCXX/deprecated-copy-with-user-provided-dtor.cpp>

I suppose adding the respective RUN lines with `-fms-compatibility` to all of them is the way to go. I will try that tomorrow to see if something breaks and then update this patch.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D133354/new/

https://reviews.llvm.org/D133354



More information about the cfe-commits mailing list