[PATCH] D159463: [include-cleaner] Map the 4-argument move overload to the algorithm header.
Viktoriia Bakalova via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Wed Sep 6 04:39:22 PDT 2023
This revision was landed with ongoing or failed builds.
This revision was automatically updated to reflect the committed changes.
Closed by commit rGd71adebb9fb8: [include-cleaner] Map the 4-argument move overload to the algorithm header. (authored by VitaNuo).
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D159463/new/
https://reviews.llvm.org/D159463
Files:
clang-tools-extra/include-cleaner/lib/FindHeaders.cpp
clang-tools-extra/include-cleaner/unittests/FindHeadersTest.cpp
Index: clang-tools-extra/include-cleaner/unittests/FindHeadersTest.cpp
===================================================================
--- clang-tools-extra/include-cleaner/unittests/FindHeadersTest.cpp
+++ clang-tools-extra/include-cleaner/unittests/FindHeadersTest.cpp
@@ -546,6 +546,16 @@
"move",
"<algorithm>",
},
+ {
+ R"cpp(
+ namespace std {
+ template<class ExecutionPolicy, class ForwardIt1, class ForwardIt2>
+ ForwardIt2 move(ExecutionPolicy&& policy,
+ ForwardIt1 first, ForwardIt1 last, ForwardIt2 d_first);
+ })cpp",
+ "move",
+ "<algorithm>",
+ },
{
R"cpp(
namespace std {
Index: clang-tools-extra/include-cleaner/lib/FindHeaders.cpp
===================================================================
--- clang-tools-extra/include-cleaner/lib/FindHeaders.cpp
+++ clang-tools-extra/include-cleaner/lib/FindHeaders.cpp
@@ -125,8 +125,10 @@
if (FD->getNumParams() == 1)
// move(T&& t)
return tooling::stdlib::Header::named("<utility>");
- if (FD->getNumParams() == 3)
+ if (FD->getNumParams() == 3 || FD->getNumParams() == 4)
// move(InputIt first, InputIt last, OutputIt dest);
+ // move(ExecutionPolicy&& policy, ForwardIt1 first,
+ // ForwardIt1 last, ForwardIt2 d_first);
return tooling::stdlib::Header::named("<algorithm>");
} else if (FName == "remove") {
if (FD->getNumParams() == 1)
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D159463.556005.patch
Type: text/x-patch
Size: 1524 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20230906/54fe35bd/attachment.bin>
More information about the cfe-commits
mailing list