[PATCH] D56902: [clang-tidy] Use getStripPluginsAdjuster
Kadir Cetinkaya via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Mon Jan 21 02:10:41 PST 2019
This revision was automatically updated to reflect the committed changes.
Closed by commit rL351738: [clang-tidy] Use getStripPluginsAdjuster (authored by kadircet, committed by ).
Herald added a subscriber: llvm-commits.
Repository:
rL LLVM
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D56902/new/
https://reviews.llvm.org/D56902
Files:
clang-tools-extra/trunk/clang-tidy/ClangTidy.cpp
Index: clang-tools-extra/trunk/clang-tidy/ClangTidy.cpp
===================================================================
--- clang-tools-extra/trunk/clang-tidy/ClangTidy.cpp
+++ clang-tools-extra/trunk/clang-tidy/ClangTidy.cpp
@@ -528,24 +528,8 @@
return AdjustedArgs;
};
- // Remove plugins arguments.
- ArgumentsAdjuster PluginArgumentsRemover =
- [](const CommandLineArguments &Args, StringRef Filename) {
- CommandLineArguments AdjustedArgs;
- for (size_t I = 0, E = Args.size(); I < E; ++I) {
- if (I + 4 < Args.size() && Args[I] == "-Xclang" &&
- (Args[I + 1] == "-load" || Args[I + 1] == "-add-plugin" ||
- StringRef(Args[I + 1]).startswith("-plugin-arg-")) &&
- Args[I + 2] == "-Xclang") {
- I += 3;
- } else
- AdjustedArgs.push_back(Args[I]);
- }
- return AdjustedArgs;
- };
-
Tool.appendArgumentsAdjuster(PerFileExtraArgumentsInserter);
- Tool.appendArgumentsAdjuster(PluginArgumentsRemover);
+ Tool.appendArgumentsAdjuster(getStripPluginsAdjuster());
Context.setEnableProfiling(EnableCheckProfile);
Context.setProfileStoragePrefix(StoreCheckProfile);
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D56902.182763.patch
Type: text/x-patch
Size: 1216 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20190121/1078f9c6/attachment.bin>
More information about the cfe-commits
mailing list