[clang] 80a6968 - [clang][deps] NFC: Update documentation
Jan Svoboda via cfe-commits
cfe-commits at lists.llvm.org
Wed Feb 23 06:46:27 PST 2022
Author: Jan Svoboda
Date: 2022-02-23T15:46:20+01:00
New Revision: 80a696898cd57f00297e06714bd5118ce7308f3e
URL: https://github.com/llvm/llvm-project/commit/80a696898cd57f00297e06714bd5118ce7308f3e
DIFF: https://github.com/llvm/llvm-project/commit/80a696898cd57f00297e06714bd5118ce7308f3e.diff
LOG: [clang][deps] NFC: Update documentation
In D113473, the dependency scanner stopped emitting "-fmodule-map-file=" arguments. Potential build systems are expected to not add any such arguments on their own. This commit removes mentions of such arguments to avoid confusion.
Added:
Modified:
clang/include/clang/Tooling/DependencyScanning/DependencyScanningTool.h
clang/include/clang/Tooling/DependencyScanning/ModuleDepCollector.h
clang/lib/Tooling/DependencyScanning/DependencyScanningTool.cpp
Removed:
################################################################################
diff --git a/clang/include/clang/Tooling/DependencyScanning/DependencyScanningTool.h b/clang/include/clang/Tooling/DependencyScanning/DependencyScanningTool.h
index 2eb7a35b27b91..54c3c9543dedd 100644
--- a/clang/include/clang/Tooling/DependencyScanning/DependencyScanningTool.h
+++ b/clang/include/clang/Tooling/DependencyScanning/DependencyScanningTool.h
@@ -16,9 +16,9 @@
#include "llvm/ADT/StringSet.h"
#include <string>
-namespace clang{
-namespace tooling{
-namespace dependencies{
+namespace clang {
+namespace tooling {
+namespace dependencies {
/// The full dependencies and module graph for a specific input.
struct FullDependencies {
@@ -51,15 +51,13 @@ struct FullDependencies {
/// be located.
/// \param LookupModuleDeps This function is called to collect the full
/// transitive set of dependencies for this
- /// compilation and fill in "-fmodule-map-file="
- /// arguments.
+ /// compilation.
std::vector<std::string> getAdditionalArgs(
std::function<StringRef(ModuleID)> LookupPCMPath,
std::function<const ModuleDeps &(ModuleID)> LookupModuleDeps) const;
/// Get additional arguments suitable for appending to the original Clang
- /// command line, excluding arguments containing modules-related paths:
- /// "-fmodule-file=", "-fmodule-map-file=".
+ /// command line, excluding "-fmodule-file=" arguments.
std::vector<std::string> getAdditionalArgsWithoutModulePaths() const;
};
diff --git a/clang/include/clang/Tooling/DependencyScanning/ModuleDepCollector.h b/clang/include/clang/Tooling/DependencyScanning/ModuleDepCollector.h
index d1a7aab8c24b1..c2e9541db68e0 100644
--- a/clang/include/clang/Tooling/DependencyScanning/ModuleDepCollector.h
+++ b/clang/include/clang/Tooling/DependencyScanning/ModuleDepCollector.h
@@ -111,15 +111,13 @@ struct ModuleDeps {
/// be located.
/// \param LookupModuleDeps This function is called to collect the full
/// transitive set of dependencies for this
- /// compilation and fill in "-fmodule-map-file="
- /// arguments.
+ /// compilation.
std::vector<std::string> getCanonicalCommandLine(
std::function<StringRef(ModuleID)> LookupPCMPath,
std::function<const ModuleDeps &(ModuleID)> LookupModuleDeps) const;
/// Gets the canonical command line suitable for passing to clang, excluding
- /// arguments containing modules-related paths: "-fmodule-file=", "-o",
- /// "-fmodule-map-file=".
+ /// "-fmodule-file=" and "-o" arguments.
std::vector<std::string> getCanonicalCommandLineWithoutModulePaths() const;
};
diff --git a/clang/lib/Tooling/DependencyScanning/DependencyScanningTool.cpp b/clang/lib/Tooling/DependencyScanning/DependencyScanningTool.cpp
index 739712baadd06..26f91961c2bbd 100644
--- a/clang/lib/Tooling/DependencyScanning/DependencyScanningTool.cpp
+++ b/clang/lib/Tooling/DependencyScanning/DependencyScanningTool.cpp
@@ -9,9 +9,9 @@
#include "clang/Tooling/DependencyScanning/DependencyScanningTool.h"
#include "clang/Frontend/Utils.h"
-namespace clang{
-namespace tooling{
-namespace dependencies{
+namespace clang {
+namespace tooling {
+namespace dependencies {
std::vector<std::string> FullDependencies::getAdditionalArgs(
std::function<StringRef(ModuleID)> LookupPCMPath,
More information about the cfe-commits
mailing list