From: Jan Svoboda Date: Wed, 23 Feb 2022 14:18:00 +0000 (+0100) Subject: [clang][deps] NFC: Update documentation X-Git-Tag: upstream/15.0.7~15543 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=80a696898cd57f00297e06714bd5118ce7308f3e;p=platform%2Fupstream%2Fllvm.git [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. --- diff --git a/clang/include/clang/Tooling/DependencyScanning/DependencyScanningTool.h b/clang/include/clang/Tooling/DependencyScanning/DependencyScanningTool.h index 2eb7a35..54c3c95 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 -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 getAdditionalArgs( std::function LookupPCMPath, std::function 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 getAdditionalArgsWithoutModulePaths() const; }; diff --git a/clang/include/clang/Tooling/DependencyScanning/ModuleDepCollector.h b/clang/include/clang/Tooling/DependencyScanning/ModuleDepCollector.h index d1a7aab..c2e9541 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 getCanonicalCommandLine( std::function LookupPCMPath, std::function 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 getCanonicalCommandLineWithoutModulePaths() const; }; diff --git a/clang/lib/Tooling/DependencyScanning/DependencyScanningTool.cpp b/clang/lib/Tooling/DependencyScanning/DependencyScanningTool.cpp index 739712b..26f9196 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 FullDependencies::getAdditionalArgs( std::function LookupPCMPath,