[all-commits] [llvm/llvm-project] f95ff8: [clang][deps] NFC: Handle `DependencyOutputOptions...
Jan Svoboda via All-commits
all-commits at lists.llvm.org
Mon Jun 14 06:16:30 PDT 2021
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: f95ff81627212a8db9f942aafa91392096538847
https://github.com/llvm/llvm-project/commit/f95ff81627212a8db9f942aafa91392096538847
Author: Jan Svoboda <jan_svoboda at apple.com>
Date: 2021-06-14 (Mon, 14 Jun 2021)
Changed paths:
M clang/include/clang/Tooling/DependencyScanning/DependencyScanningWorker.h
M clang/lib/Tooling/DependencyScanning/DependencyScanningTool.cpp
M clang/lib/Tooling/DependencyScanning/DependencyScanningWorker.cpp
M clang/lib/Tooling/DependencyScanning/ModuleDepCollector.cpp
Log Message:
-----------
[clang][deps] NFC: Handle `DependencyOutputOptions` only once
There's no need to pass `DependencyOutputOptions` to each call of `handleFileDependency`, since the options don't ever change.
This patch adds new `handleDependencyOutputOpts` method to the `DependencyConsumer` interface and the dependency scanner uses it to report the options only once.
Reviewed By: dexonsmith
Differential Revision: https://reviews.llvm.org/D104104
Commit: 85208b96b85f6f3e502cf4b7fd5f440434d1c7e5
https://github.com/llvm/llvm-project/commit/85208b96b85f6f3e502cf4b7fd5f440434d1c7e5
Author: Jan Svoboda <jan_svoboda at apple.com>
Date: 2021-06-14 (Mon, 14 Jun 2021)
Changed paths:
M clang/lib/Tooling/DependencyScanning/DependencyScanningWorker.cpp
Log Message:
-----------
[clang][deps] NFC: Stop using moved-from object
The dependency scanning worker uses `std::move` to "reset" `DependencyOutputOptions` in the `CompilerInstance` that performs the implicit build. It's probably preferable to replace the object with value-initialized instance, rather than depending on the behavior of a moved-from object.
Reviewed By: dexonsmith
Differential Revision: https://reviews.llvm.org/D104106
Compare: https://github.com/llvm/llvm-project/compare/bb8ce25e8821...85208b96b85f
More information about the All-commits
mailing list